Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Donations accepted in many coin/token types. List & Addresses:
- // https://sites.google.com/view/nanogamescrashscripts/home/donation-addresses
- var config = {
- mainTitle: { label: '*** Fargo 17; Adapted by Nubs27 ***', type: 'title' },
- bet: { label: 'Base Bet', value: 0.0001, type: 'number' },
- };
- function main () {
- var bet = config.bet.value;
- var cashOut = 1.6;
- var skip1 = 0; // after 3rd loss
- var skip2 = 0; // after 4th loss
- var skip3 = 0; // after 5th loss
- var skip4 = 0; // after 6th loss
- var skip5 = 0; // after 7th loss
- var skip6 = 0; // after 8th loss
- var skip7 = 0; // after 9th loss
- var currentBet = bet;
- var losses = 0;
- var skip = 0;
- var lostGames = 0;
- var waitXgames = 0;
- var winStreak = 0;
- var lossStreak = 0;
- var lastResult = 'WON';
- var lastGame = History[0];
- console.log('%c----------Start!----------', 'color: green; font-weight:bold');
- log.info('----------Start!----------', 'color: green; font-weight:bold');
- engine.on('GAME_STARTING', function () {
- if (lastResult == 'LOST') {
- currentBet = (currentBet * 1.49); //bet increase on loss
- cashOut = (losses / currentBet) + 1.04; //cashout multiplier increase on loss
- if (lostGames >= 1) {
- waitXgames = 0;
- if (lostGames == 3) {skip = skip1;}
- if (lostGames == 4) {skip = skip2;}
- if (lostGames == 5) {skip = skip3;}
- if (lostGames == 6) {skip = skip4;}
- if (lostGames == 7) {skip = skip5;}
- if (lostGames == 8) {skip = skip6;}
- if (lostGames >= 9) {skip = skip7;}
- }
- console.log('Lost Section - Current Bet = ' + currentBet + ' PayOut = ' + cashOut);
- }
- if (lastResult == 'WON') {
- cashOut = 1.6;
- //if win
- if (winStreak >= 2) {
- currentBet = currentBet * 1.10; //bet increase on win
- cashOut = cashOut + 0.01; //cashout increase on win
- }else{
- console.log('%cBetting Reset', 'color: green; font-weight:bold');
- log.info('Betting Reset');
- currentBet = bet; //reset betting on win
- cashOut = 1.2;
- }
- lostGames = 0;
- skip = 0;
- cashOut = 1.6;
- //reset betting on 10 winStreak
- if (winStreak == 7) {
- console.log('%c7 wins', 'color: green; font-weight:bold');
- log.info('7 wins');
- console.log('%cBetting Reset', 'color: green; font-weight:bold');
- log.info('Betting Reset');
- currentBet = bet; //reset bet
- cashOut = 1.2; //reset the cashout
- }
- }
- if (waitXgames >= skip) {
- if (lastResult == 'WON') {
- console.log('%cYou win', 'color: green; font-weight:bold');
- log.info('You Won');
- }
- if (lastResult == 'LOST') {
- console.log('%cYou lose', 'color: red; font-weight:bold');
- log.info('You Lost');
- }
- if (winStreak > 1) {
- console.log('Current win streak is' + winStreak);
- log.info('Current win streak is' + winStreak);
- }
- if (lossStreak > 1) {
- console.log('Current loss streak is' + lossStreak);
- log.info('Current loss streak is' + lossStreak);
- }
- console.log('--------New Round--------');
- log.info('--------New Round--------');
- console.log('', currentBet, currency.currencyName, 'bet at', Math.round(cashOut * 100) / 100, 'x');
- engine.bet(Math.floor(currentBet), Math.round(cashOut * 100) / 100);
- }else{
- console.log('--------New Round--------');
- log.info('--------New Round--------');
- console.log('Cooling off. No bets this round.');
- log.info('Cooling off. No bets this round.');
- console.log('Current loss streak is', lossStreak);
- log.info('Current loss streak is', lossStreak);
- winStreak = 0;
- }
- });
- //Crash Occurred
- engine.on('GAME_ENDED', function (data) {
- var History = engine.getHistory();
- lastGame = History[0];
- if (History[0] / 100 >= cashOut) {
- console.log('Game [Busted] at ' + (History[0] / 100) + 'x');
- waitXgames++;
- }else{
- waitXgames++;
- }
- if (lastGame.cashedAt) {
- lastResult = 'WON';
- lossStreak = 0;
- winStreak++;
- }else{
- lastResult = 'LOST';
- winStreak = 0;
- lossStreak++;
- lostGames++;
- losses = losses + currentBet;
- }
- });
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement