Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Version 1.6 - Created by FREEDOM
- // This is exactly the same as the AUTO function on the site except this one throws in
- // a random amount of rounds to stop betting when it lost only to begin again after
- // waiting. This is to reduce the chance of it riding a red train while afking.
- //
- // Chrome: Press f12 and switch to the console tab. Stats and outputs will be shown there.
- var idontwannaspendthismuch = 8;
- var roadtoknife = [1,2,3,5,8,13,21,34];
- var luckynumber_special = 17;
- var doingit = false;
- var yess = 0;
- var nooo = 0;
- var specialattack = 0;
- var ncra = 0;
- var greentrain = 0;
- var redtrain = 0;
- var prevg = false;
- var prevw = false;
- var mred = 0;
- var mgreen = 0;
- var xgreen = 0;
- var xred = 0;
- var lgreen = 0;
- var lred = 0;
- var my_dick = 0;
- var betAmount = 4; // Set the amount to bet. Must be more than 1
- var cashOut = 2; // x
- var noNegative = -10000; // If your net goes this much negative it stops betting
- var Rmin = 1; // Minimum amount of rounds to wait before betting again after a loss
- var Rmax = 5; // Maximum amount of rounds to wait before betting again after a lossµ
- var pulloutMethod = 1; // 1 = Rmin to Rmax Pullout, 2 = Multiplier Pullout (set amount below)
- var pulloutMultiAmount = 3; //2: Amount of times to let it crash below cashOut before betting again
- //============= Modify Past this line at your own risk ==================
- var net = 0;
- var minBet = 1;
- var gamesPlayed = 0;
- var gamesWon = 0;
- var gamesLost = 0;
- var gamesNotEntered = 0;
- var maxBet = engine.getMaxBet();
- var ID = engine.getSteamID();
- var balance = engine.getBalance();
- var curBR = balance;
- var maxBR = balance;
- var minBR = balance;
- var startBR = balance;
- var cashedOut = true;
- var pullout = 0;
- var pullout2 = 0;
- var pullout2count = 0;
- var count = 0;
- var gameResult;
- var gameInside;
- errorHandling();
- engine.on('game_starting', function(info) {
- //console.log('Game Starting in ' + info.time_till_start);
- placeBet();
- });
- engine.on('game_started', function(data) {
- //console.log('Game Started', data);
- });
- engine.on('game_crash', function(data) {
- console.log('Game crashed at ', (data.game_crash/100));
- ncra = data.game_crash;
- gameResult = engine.lastGamePlay();
- gameInside = engine.lastGamePlayed();
- if (gameResult=="WON"&&gameInside==true) {
- netUpdate();
- specialattack = specialattack + 1;
- if (prevg == true){
- greentrain = greentrain + 1;
- redtrain = 0;
- }
- else{
- redtrain = redtrain + 1;
- greentrain = 0;
- }
- gamesWon += 1;
- betAmount = 4;
- my_dick = 0;
- gamesPlayed += 1;
- prevg = true;
- logg();
- }
- else if (gameResult=="LOST"&&gameInside==true) {
- netUpdate();
- gamesLost += 1;
- betAmount = betAmount *2; //This is the Martingale
- if (betAmount >= idontwannaspendthismuch){
- engine.stop();
- }
- my_dick = my_dick + 1; //This is the Golden Number State, to chose the position of the Golden Number Array
- if (my_dick > 7) { //Best name ever
- my_dick = 0;
- };
- gamesPlayed += 1;
- prevg = false;
- pulloutMethodM();
- }
- else if (gameInside==false&&(pullout>0||pullout2count>0)) {
- pullout2 = (data.game_crash/100);
- pulloutCalc();
- }
- });
- engine.on('player_bet', function(data) {
- if (data.steamid == ID) {
- cashedOut = false;
- }
- });
- engine.on('cashed_out', function(resp) {
- if (resp.steamid == ID) {
- cashedOut = true;
- }
- });
- engine.on('msg', function(data) {
- //console.log('Chat message!...');
- });
- engine.on('connect', function() {
- //console.log('Client connected, this wont happen when you run the script');
- });
- engine.on('disconnect', function() {
- //console.log('Client disconnected');
- });
- function errorHandling() {
- if (betAmount>=1&&betAmount<=50000);
- else {
- console.log('Wrong betting amount','\n','Bot stopped');
- engine.stop();
- }
- if (cashOut>=1);
- else {
- console.log('Multiplier setting is wrong','\n','Bot stopped');
- engine.stop();
- }
- if (Rmax<Rmin) {
- console.log('Random range is wrong. Rmax cannot be lower than Rmin','\n','Bot stopped');
- engine.stop();
- }
- if (pulloutMethod>=3||pulloutMethod<=0) {
- console.log('Wrong pullout method selected','\n','Bot stopped');
- engine.stop();
- }
- if (noNegative>=0) {
- console.log('noNegative must be in the negatives','\n','Bot stopped');
- engine.stop();
- }
- console.log('No errors, bot started');
- }
- function placeBet() {
- if (pullout2count==0&&pullout==0&&(net/100)>noNegative) {
- cashedOut = false;
- if (specialattack >= luckynumber_special){
- betAmount = betAmount*4;
- special();
- specialattack = 0;
- }
- else{
- cashOut = 2;
- }
- engine.placeBet( betAmount*100, cashOut*100, false );
- console.log('Placing a bet: ',betAmount);
- }
- else {
- if (pullout>0||pullout2count>0) {
- }
- else {
- console.log('Bet amount invalid. Bot stopped');
- engine.stop();
- }
- }
- }
- function pulloutMethodM() {
- switch(pulloutMethod) {
- case 1:
- pullout = (roadtoknife[my_dick]);
- logg();
- console.log('Lost a bet, waiting for ',pullout,' rounds before betting again');
- break;
- case 2:
- console.log('debug 3')
- pullout2count = pulloutMultiAmount;
- logg();
- console.log('Waiting ',pullout2count,'rounds were the crash is less than ',cashOut);
- break;
- default:
- console.log('Wrong method specified. Type in 1 or 2','\n','Bot Stopped');
- engine.stop();
- break;
- }
- }
- function pulloutCalc() {
- switch(pulloutMethod) {
- case 1:
- pullout -= 1;
- console.log('Pullout is at ',pullout);
- break;
- case 2:
- if (pullout2<=cashOut) {
- pullout2count -= 1
- console.log('Pullout is at ',pullout2count);
- }
- break;
- default:
- console.log('Pullout error','\n','Bot stopped');
- engine.stop();
- }
- }
- function netUpdate() {
- curBR = engine.getBalance();
- if (curBR<minBR) {
- minBR = curBR;
- }
- else if (curBR>maxBR) {
- maxBR = curBR;
- }
- net = curBR - startBR;
- }
- function special() {
- //special bet will get a number between 2 and 10 and propose it as multiplier
- //the closest to 2 the greater is the chance to get the number as multiplier
- var first = [2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,5,5,5,5,5,5,6,6,6,6,7,7,7,8,8,9,10];
- var second = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,5,5,5,5,5,5,6,6,6,6,7,7,7,8,8,9];
- var third = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,5,5,5,5,5,5,6,6,6,6,7,7,7,8,8,9];
- var fch = first[Math.floor((Math.random() * (first.length)) + 0)];
- var sch = second[Math.floor((Math.random() * second.length) + 0)];
- var tch = third[Math.floor((Math.random() * third.length) + 0)];
- fch = String(fch);
- sch = String(sch);
- tch = String(tch);
- var nm = parseFloat((fch + "." + sch + tch));
- cashOut = nm;
- console.log("Cash out multiplier : ",nm);
- doingit = true;
- }
- function logg() {
- if ((doingit == true) && (ncra >= cashOut)){
- yess = yess + 1;
- doingit = false;
- }
- if ((doingit == true) && (ncra < cashOut)){
- nooo = nooo + 1;
- doingit = false;
- }
- console.log('\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n');
- if ( (ncra) < 200){
- mred = mred + 1;
- mgreen = 0;
- }
- else{
- mgreen = mgreen + 1;
- mred = 0;
- }
- if (mgreen > xgreen){
- xgreen = mgreen;
- };
- if (mred > xred){
- xred = mred;
- };
- if (greentrain > lgreen){
- lgreen = greentrain;
- };
- if (redtrain > lred){
- lred = redtrain;
- };
- console.log('Total games played: ',gamesPlayed);
- console.log('Total games won/lost: ',gamesWon,'/',gamesLost , '|| Special in ', (luckynumber_special - specialattack), 'round(s) ||' , ' Specials won/lost ', yess,"/",nooo);
- console.log('Golden number state',my_dick);
- console.log('Gone through : Longest green train ', lgreen, '- Longest red train ', lred);
- console.log('In the game : Longest green train ', xgreen, '- Longest red train ', xred);
- console.log('Net: ', net/100);
- if (betAmount >= idontwannaspendthismuch){
- console.log("Bot stopped since the betting amount exceded ",idontwannaspendthismuch);
- }
- }
- function checkBet(moni) {
- return (moni>=1&&moni<=50000);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement