Advertisement
Guest User

The Real Nyan Chaser

a guest
Oct 22nd, 2017
200
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.07 KB | None | 0 0
  1. //Settings
  2. var BaseBet = 1; //Default: 20 This is the base bet. All formulas are controlled by this
  3. var CurrentBet = BaseBet;
  4. var MaxBet = 75; // Default: 250 This is the maximum amount that the bot will bet
  5. var BaseMultiplier = 1000; //Default: 250 This is the multiplier *100 that the formulas use
  6. var CurrentMultiplier = BaseMultiplier;
  7.  
  8. //Do NOT change anything below this line.
  9. var CurrentGameID = 0;
  10. var LastResult = "Lost";
  11. var ConLoss = 1;
  12. var GamesPlayed = 0;
  13. var AvgCashOut = 2;
  14. var PrevCashOut = 2;
  15. var TotalCashOut = 0;
  16. var StartBalance = engine.getBalance();
  17. var CurrBalance = engine.getBalance();
  18. var Profit = 0;
  19. var PrevCashOut = 2;
  20. var RaisingBet1k = 400;
  21. var RaisedBet = 0;
  22. var LastResult = "WON";
  23.  
  24.  
  25.  
  26. //Status & Welcome Message
  27. console.clear();
  28. console.log("~~~~~~ Nubs27's BustaBit NYAN Chaser ~~~~~~");
  29. console.log("My username is: " + engine.getUsername());
  30. console.log("Starting balance: " + (engine.getBalance() / 100) + " bits");
  31. console.log(" ~~~~~~ BustaBit Bot Started ~~~~~~");
  32.  
  33.  
  34. //Current Game
  35. engine.on('game_starting', function(info) {
  36. CurrentGameID = info.game_id;
  37. CurrBalance = engine.getBalance();
  38. console.log('---------------------');
  39. console.log('[Info] Game #' + CurrentGameID);
  40. console.log('[Stats] Average Crash ' + AvgCashOut + 'x');
  41. console.log('[Stats] Current Session Profit ' + Profit + ' Bits');
  42. strategy1k();
  43. placebet();
  44. }
  45. );
  46.  
  47.  
  48. //Strategy
  49. function strategy1k() {
  50. BaseBet = 1;
  51. if (ConLoss > RaisingBet1k) {
  52. ConLoss = 0;
  53. RaisedBet++;
  54. CurrentBet++;
  55. RaisingBet1k = (RaisingBet1k - 100);
  56. }
  57. if (ConLoss > 2800) {
  58. CurrentBet = (CurrentBet + 2);
  59. }
  60. }
  61.  
  62.  
  63. function placebet() {
  64. CurrentGameID = CurrentGameID.toString();
  65. if (CurrentGameID.endsWith('3')) {
  66. CurrentBet = (CurrentBet * 2);
  67. }
  68. if (CurrentBet > MaxBet) {
  69. CurrentBet = MaxBet;
  70. console.log('[Warning] Current Bet EXCEEDS maximum bet, reducing bet to' + MaxBet);
  71. }
  72. CurrentBet = Math.round(CurrentBet);
  73. engine.placeBet(Math.ceil(CurrentBet * 100), Math.ceil(CurrentMultiplier * 100), false);
  74. console.log('[BustaBot] Betting ' + (CurrentBet) + ' Bits at ' + CurrentMultiplier + 'x');
  75. if (CurrentGameID.endsWith('3')) {
  76. CurrentBet = (CurrentBet / 2);
  77. }
  78. }
  79.  
  80. //Game Ends
  81. engine.on('game_crash', function(data) {
  82. GamesPlayed++;
  83. TotalCashOut += data.game_crash;
  84. AvgCashOut = ((TotalCashOut / GamesPlayed) / 100);
  85. AvgCashOut = AvgCashOut.toFixed(2);
  86. PrevCashOut = (data.game_crash / 100);
  87. CurrBalance = engine.getBalance();
  88. Profit = ((CurrBalance - StartBalance) / 100);
  89. console.log('[Stats] Game Crashed @ '+ PrevCashOut + 'x');
  90. console.log('[Info] ' + (RaisingBet1k - ConLoss) + ' Games until bet is raised');
  91. if (PrevCashOut > BaseMultiplier) {
  92. LastResult = "WON";
  93. ConLoss = 0;
  94. CurrentBet = BaseBet;
  95. CurrentMultiplier = BaseMultiplier;
  96. }else{
  97. LastResult = "LOST";
  98. ConLoss++;
  99. }
  100. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement