Skip to content

Instantly share code, notes, and snippets.

@dsetzer
Last active August 18, 2019 04:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save dsetzer/45541164dc77063487618e8fb476c9c9 to your computer and use it in GitHub Desktop.
Save dsetzer/45541164dc77063487618e8fb476c9c9 to your computer and use it in GitHub Desktop.
bustadice flat betting script
const baseBet = 100;
const basePayout = 1.2;
const baseMulti = 2;
const postBet = 1;
let currentBet = baseBet;
let startBal = this.balance;
let prevBal = this.balance;
while(true){
prevBal = this.balance;
const { multiplier } = await this.bet(currentBet, basePayout)
if(multiplier < basePayout){
startBal -= (currentBet * postBet);
currentBet *= baseMulti
startBal += (currentBet * postBet);
}
if(this.balance >= startBal && prevBal < startBal){
currentBet = baseBet
startBal = this.balance;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment