Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var baseBet = 2, // 10 bits
- baseCashout = 2, // Cashout at x1.28
- maxLoss = 5; // Amount of loss the bot will keep betting.
- var Simulation = false; // (true/false) Setting this to true will make the bot to simulate a betting run.
- //// ^EDIT OVER THIS LINE^ \\\\
- var bet = 2;
- var cashout = 5;
- var lastBet = 2;
- var lossStreak = 0;
- var firstGame = true;
- var profit = 0;
- var chill = false;
- var wins = 0;
- var loss = 1.35;
- engine.on('game_starting', function(){
- if(lossStreak<maxLoss){
- console.log("Betting "+bet+" Bits on x"+cashout);
- if(Simulation){
- lastBet = bet;
- }else{
- engine.placeBet(bet*100, (cashout*100), function(){
- lastBet = bet;
- });
- }
- }else{
- console.log("Max loss reached! Passing one game then resetarting.");
- chill = true;
- bet = baseBet;
- cashout = baseCashout;
- lossStreak = 0;
- }
- });
- engine.on('game_crash', function(data){
- if(data.game_crash/100<cashout && !firstGame && !chill){
- loss++;
- console.log("Game crashed under x"+cashout+" :( ("+wins+" Wins | "+loss+" Loses)");
- profit -= lastBet;
- console.log("Current Profit: "+profit.toFixed(2));
- lossStreak++;
- if(lossStreak==1){
- cashout = 1.25;
- bet *= 4;
- }
- if(lossStreak>1){
- cashout = 1.33;
- bet *= 4;
- }
- }else{
- if(!firstGame && !chill){
- wins++;
- console.log("Successful bet! :) ("+wins+" Wins | "+loss+" Loses)");
- profit += ((lastBet*cashout)-lastBet);
- console.log("Current Profit: "+profit.toFixed(2));
- bet = baseBet;
- cashout = baseCashout;
- lossStreak = 0;
- }
- }
- firstGame = false;
- if(chill) chill = false;
- });
- function roundToTwo(num) {
- return +(Math.round(num + "e+2") + "e-2");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement