Advertisement
Guest User

Untitled

a guest
Dec 13th, 2018
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.37 KB | None | 0 0
  1. const skipGame = 3
  2. const base = 100
  3. const maxBet = 5
  4. const maxWin = 1
  5. const minBaseBet = 1
  6. const multiple = 2
  7. const uprate = 2
  8. const maxBetStop = 1
  9. const maxwinstop = 0
  10.  
  11. let currentBet = base
  12. let count = 0
  13. let bet = false
  14. let lossCount = 0
  15. let winCount = 0
  16.  
  17. while (true) {
  18. if (!bet) {
  19. const {multiplier} = await this.bet(minBaseBet * 100, 2)
  20. if (multiplier < 2) {
  21. count++
  22. } else {
  23. if (count >= skipGame) {
  24. bet = true
  25. winCount = 0
  26. }
  27. count = 0
  28. }
  29. } else {
  30. const {multiplier} = await this.bet(Math.round(currentBet) * 100, 2)
  31. if (multiplier < multiple) {
  32. lossCount++
  33. if (lossCount >= maxBet) {
  34. if (maxBetStop) {
  35. this.stop()
  36. } else {
  37. lossCount = 0
  38. winCount = 0
  39. currentBet = base
  40. bet = false
  41. }
  42. }
  43. currentBet *= uprate
  44. } else {
  45. lossCount = 0
  46. winCount++
  47. currentBet = base
  48. if (winCount >= maxWin) {
  49. if (maxwinstop) {
  50. this.stop()
  51. } else {
  52. bet = false
  53. }
  54. }
  55. }
  56. }
  57. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement