Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Script Name: Tumbling Weeds
- // Author: Borken 05-25-2018
- // Donations sent to Borken
- var DivideByFactorBase=200; // CurBal / 100 will be starting bet and default bet
- var DivideByLowLimit=40; // CurBal / 30 will be biggest bet.
- var CashoutPercentageBase=131; // 1.31x cashout (doesn't change)
- var CashoutMultiplier=4.5; // On Loss ethos bet multiplier
- var WinCountMax=5; // Stop after This many wins in a row.
- // Optional control variables:
- var SkipOnLoss=true; // After a loss, allow a random # of rounds to be skipped before attempting recovery.
- var SkipMax=2; // Randomly skip up to this many rounds before attempting recovery process.
- // Allow bet to increase in a cycle and repeat
- var IncreaseBetCycling = true; // Slowly increase bet until LowLimit is hit. This is done by slowly decreasing DivideBy therefore increasing bet.
- var GrowthRate=1.6; // DivideBy decreases by (WinCount * GrowthRate), so it bets more and more expenontially until LowLimit is reached then resets.
- // Internal not to be set
- var CashoutPercentage = CashoutPercentageBase;
- var DivideByFactor=DivideByFactorBase;
- var BitsToBet=0;
- var BitsToBetBase;
- var WinCount = 0;
- var CashoutOffSet=0;
- var LossCount=0;
- var Pause=false;
- var SkipCount = 0;
- var SkipStarted=false;
- var SkipReady=false;
- var MaxBet=0;
- engine.on('game_starting', function(data) {
- BitsToBetBase= engine.getBalance()/100/DivideByFactor;
- MaxBet=engine.getBalance()/100/20;
- if (engine.lastGamePlay() == 'LOST' ) {
- if (SkipOnLoss && !SkipStarted && !SkipReady) {
- SkipStarted=true;
- SkipCount=0;
- console.log('ResetSkip');
- BitsToBet*=CashoutMultiplier;
- } else {
- if (SkipReady) {
- LossCount++;
- WinCount=0;
- BitsToBet*=CashoutMultiplier;
- }
- }
- } else if (engine.lastGamePlay() == 'WON' && !Pause ) {
- SkipReady=false;
- SkipCount=0;
- BitsToBet=BitsToBetBase;
- if (BitsToBet > MaxBet) DivideByFactor=DivideByFactorBase;
- WinCount++;
- if (WinCount >= WinCountMax) Pause=true;
- LossCount=0;
- if (IncreaseBetCycling) DivideByFactor-=(GrowthRate* WinCount);
- if (DivideByFactor < DivideByLowLimit) DivideByFactor=DivideByFactorBase;
- } else if (!Pause) {
- if (SkipStarted) SkipCount++;
- if (SkipCount > (Math.random()) * SkipMax) {
- SkipStarted=false;
- SkipReady=true;
- }
- if (SkipCount ==0) BitsToBet=BitsToBetBase;
- }
- CashoutOffSet=0;
- if (!Pause && !SkipStarted) engine.placeBet(Math.floor(BitsToBet)*100 ,Math.floor(CashoutPercentage+CashoutOffSet));
- console.log('WinCount: ' + WinCount);
- console.log('LossCount: ' + LossCount);
- console.log('DivideBy: ' + DivideByFactor);
- console.log('MaxBet: ' + MaxBet);
- console.log('Bits Bet: ' + BitsToBet);
- if (SkipOnLoss) {
- console.log('SkipStarted: ' + SkipStarted);
- console.log('SkipCount: ' + SkipCount);
- }
- console.log(' ');
- });
- engine.on('game_crash', function(data) {
- if (data.game_crash <= CashoutPercentageBase-1) {
- Pause=false;
- WinCount=0;
- } else {
- LossCount=0;
- }
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement