Advertisement
Ypleitez

Untitled

Nov 17th, 2023
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.68 KB | None | 0 0
  1. -- FlatBet
  2. -- by Weslley Moura
  3. -- Last updated 17/11/2023
  4. -- Donate please (Stake TIP): schnoo98
  5.  
  6. -- balance = 2 -- Disable to play for real money
  7.  
  8. div = 1000
  9. basebet = balance / div
  10.  
  11. maxMultiplier = 500 -- Max Multiplier
  12.  
  13. activeVault = true -- Activate the auto-vault
  14. vaultStop = false -- When playing in the Vault the value of `vaultProfit`
  15. vaultProfit = 0.1;
  16. vaultProfitBets = 500;
  17. resetBetVault = false;
  18.  
  19. -- Console logs and seed reset
  20. resetSeedCount = 1000 -- Defines every X bets, resets the seed
  21. printStats = 200 -- Defines every X bets, shows logs in the console
  22.  
  23. -- Notification variables
  24. currency = "usdt" -->> Coin
  25.  
  26. -- Default variables
  27. win_count = 0
  28. hits = 0
  29. hitsProfit = 0
  30. pre_roll_bet = 0
  31. nextbet = basebet
  32. metaVerify = 0
  33. chance = baseChance
  34. baseChance = 49.5
  35. multiplier = 2
  36.  
  37. TB = 0
  38. loss_count = 0
  39. betcount = 0
  40. resetSeed = 0
  41. highestBet = 0
  42. highestLosses = 0
  43. highestLossesAcc = 0
  44. highestLossesValue = 0
  45. highestProfit = 0
  46. lowestBalanceHistorical = nil
  47. wager = 0
  48. vaulted = 0
  49. playtime = os.clock()
  50. startTime = os.clock()
  51. startBalance = balance
  52. lossbet = basebet
  53.  
  54. resetstats()
  55. resetseed()
  56.  
  57. function updateLowestBalance(balance)
  58. if lowestBalanceHistorical == nil or balance < lowestBalanceHistorical then
  59. lowestBalanceHistorical = balance
  60. end
  61. end
  62.  
  63. function checkVault()
  64. if activeVault then
  65. if (bets % vaultProfitBets == 0 and profit > 0) then
  66. vaulted += profit
  67. vault(profit)
  68. resetstats()
  69. stats()
  70. end
  71. if (profit >= vaultProfit and profit > 0) then
  72. vaulted += profit
  73. vault(profit)
  74. resetstats()
  75. stats()
  76. end
  77.  
  78. if (resetBetVault and profit > 0) then
  79. nextbet = basebet
  80. end
  81. end
  82. end
  83.  
  84.  
  85. function multiplierToWinChance(multiplier)
  86. return (100-1)/multiplier
  87. end
  88.  
  89. function dobet()
  90.  
  91. TB += 1
  92. if (vaulted >= vaultProfit and vaultStop) then
  93. stop()
  94. end
  95.  
  96. betcount += 1
  97.  
  98. if (win) then
  99. win_count += 1
  100. loss_count = 0
  101. highestLossesAcc = 0
  102. multiplier = 2
  103. chance = baseChance
  104.  
  105. nextbet = basebet
  106.  
  107. else
  108. win_count = 0
  109. loss_count += 1
  110.  
  111. if loss_count % 5 == 0 then
  112. multiplier += 5
  113. end
  114.  
  115. if (multiplier >= maxMultiplier) then
  116. multiplier = maxMultiplier
  117. end
  118. chance = multiplierToWinChance(multiplier)
  119.  
  120. nextbet = basebet
  121.  
  122.  
  123.  
  124. ----------------------------------------------------------------------
  125. -- Check the maximum loss
  126. highestLossesAcc += previousbet
  127. if highestLossesAcc >= highestLossesValue then
  128. highestLossesValue = highestLossesAcc
  129. end
  130. end
  131.  
  132. -- Conditionals for notification
  133. wager += nextbet
  134.  
  135. if loss_count >= highestLosses then
  136. highestLosses = loss_count
  137. end
  138.  
  139. if nextbet >= highestBet then
  140. highestBet = nextbet
  141. end
  142.  
  143. if (profit >= highestProfit) then
  144. highestProfit = profit
  145. end
  146.  
  147. if (TB % resetSeedCount == 0) then
  148. resetSeed += 1
  149. resetseed()
  150. end
  151.  
  152. if (bets % printStats == 0) then
  153. stats()
  154. end
  155.  
  156. if nextbet < basebet then
  157. nextbet = basebet
  158. end
  159.  
  160. checkVault()
  161.  
  162. updateLowestBalance(balance)
  163. end
  164.  
  165. function format_number_with_decimal_point(number)
  166. local formatted_number = tostring(number)
  167. local k
  168.  
  169. while true do
  170. formatted_number, k = string.gsub(formatted_number, "^(-?%d+)(%d%d%d)", '%1.%2')
  171. if (k==0) then
  172. break
  173. end
  174. end
  175.  
  176. return formatted_number
  177. end
  178.  
  179. -- Display information in the console
  180. function stats()
  181. print("\n\n=======================================")
  182. print("---===>>> FlatBet")
  183. print("=======================================")
  184. print("")
  185. print("# Bets: " .. format_number_with_decimal_point(TB))
  186. print("")
  187. print("# Bets per: " .. string.format("%2.3f", betcount/(os.clock()-playtime)) .. " /second | " .. math.floor(0.5+betcount/(os.clock()-playtime)*60^2) .. " /hour | " .. math.floor(0.5+24*betcount/(os.clock()-playtime)*60^2) .. " /day")
  188. print("")
  189. print("->> Balance: "..string.format("%9.8f", balance) .. " " .. string.upper(currency))
  190. print("->> Wagered: "..string.format("%9.8f", wager) .. " " .. string.upper(currency))
  191. if lowestBalanceHistorical == nil then
  192. print("->> Lowest Balance: "..string.format("%9.8f", startBalance) .. " " .. string.upper(currency))
  193.  
  194. else
  195. print("->> Lowest Balance: "..string.format("%9.8f", lowestBalanceHistorical) .. " " .. string.upper(currency))
  196. end
  197.  
  198. print("")
  199.  
  200. print("->> Basebet: "..string.format("%9.8f", basebet) .. " " .. string.upper(currency))
  201. print("->> Loss Seq: "..string.format(loss_count))
  202. print("->> Reset Seed count: " ..resetSeed)
  203.  
  204. print("")
  205.  
  206. print("->> Highest Bet: "..string.format("%9.8f", highestBet) .. " " .. string.upper(currency))
  207. print("->> Highest Profit: "..string.format("%9.8f", highestProfit) .. " " .. string.upper(currency))
  208. print("->> Highest Loss: "..string.format("%9.8f", highestLossesValue) .. " " .. string.upper(currency))
  209. print("->> Highest Loss Seq: ".. highestLosses)
  210.  
  211. print("")
  212. print("# Vaulted: " .. string.format("%9.8f", vaulted) .. " " .. string.upper(currency))
  213. print("")
  214.  
  215. print(string.format("->> Bet: %.8f | Chance: %.2f | Bethigh: %s", nextbet, chance, tostring(bethigh)))
  216. print("---------------------------------------------")
  217. print("by Weslley Moura")
  218. print("\n")
  219. end
  220.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement