dicebot script


SUBMITTED BY: phroyd

DATE: Aug. 4, 2019, 10:07 a.m.

UPDATED: Aug. 4, 2019, 10:47 a.m.

FORMAT: Text only

SIZE: 555 Bytes

HITS: 63028

  1. chance = 0.99
  2. maxbalance = balance
  3. function getmulti()
  4. local payout=(100-1)/chance
  5. return (payout/(payout-1))
  6. end
  7. function getBaseDiv()
  8. return (math.sqrt( balance ) * 100000)
  9. end
  10. base = balance/getBaseDiv()
  11. nextbet = base
  12. function dobet()
  13. if win then
  14. base = balance/getBaseDiv()
  15. nextbet = base
  16. checkMaxBalance()
  17. else
  18. nextbet = previousbet*getmulti()
  19. end
  20. end
  21. function checkMaxBalance()
  22. if balance > maxbalance then
  23. print("new max: "..string.format("%9.8f", balance))
  24. maxbalance = balance
  25. end
  26. end

comments powered by Disqus