Created
April 16, 2022 22:19
-
-
Save thaolt/4a4d7f721c93a5214e966fb68c500f63 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var config = { | |
baseBet: { label: "base bet", value: 0.00000006, type: "number" }, | |
payout: { label: "payout", value: 3, type: "number" }, | |
stop: { label: "stop if next bet >", value: 34, type: "number" }, | |
wagerBet: { label: "wager bet", value: '0.00000006', type: "number" }, | |
}; | |
function main() { | |
var currentBet = config.baseBet.value; | |
var bet = currentBet + config.wagerBet.value; | |
var losses = 0; | |
var streak = 0; | |
var we = config.baseBet.value * (config.payout.value - 1); | |
game.onBet = function () { | |
game.bet(bet, config.payout.value).then(function (payout) { | |
if (payout > 1) { | |
currentBet = config.baseBet.value; | |
losses = 0; | |
streak = 1; | |
} else { | |
losses += currentBet; | |
streak += 1; | |
currentBet = (losses + (streak*we))/(config.payout.value - 1); | |
if (currentBet > config.stop.value) { | |
//stop loss | |
log.error( | |
"Was about to bet with payout " + | |
currentPayout + | |
" which triggers the stop" | |
); | |
game.stop(); | |
} | |
} | |
bet = currentBet + config.wagerBet.value; | |
}); | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
var config = {
}
function main() {
log.info("Start");
var bet = config.bet.value;
var mainPayout = config.payout.value;
var payout = config.payout.value;
var stopLost = config.stopLost.value;
var takeProfit = config.takeProfit.value;
var mainB = bet;
var loseS = 0;
var winS = 0;
var hb=0;
var ttw= 0;
var ttl = 0;
var k =0;
var Bbet = 0;
var profit = 0;
var profit2 = 0;
var winP = 0;
var randomNum = 0
}