Advertisement
Guest User

Untitled

a guest
Oct 13th, 2019
234
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.21 KB | None | 0 0
  1. var baseBet = 17;
  2. var cashOut = 1.5;
  3. var maxBet = 1000000;
  4. var spiders = false; //Enable this
  5.  
  6. //---------------
  7. var ourBet = baseBet;
  8. var startingBalance = engine.getBalance();
  9. var bets = [];
  10. var max;
  11.  
  12. engine.on('game_starting', function(){
  13.  
  14. if (engine.lastGamePlay()==="WON"){
  15. ourBet = ourBet + baseBet;
  16. if (ourBet > maxBet){
  17. ourBet = maxBet;
  18. }
  19.  
  20. }
  21.  
  22. if (engine.getBalance() > startingBalance){
  23. ourBet = baseBet;
  24. startingBalance = engine.getBalance();
  25. }
  26. bets.push(ourBet);
  27. max = bets.max();
  28. bets = [];
  29. bets.push(max);
  30. console.log("Max bet so far: " + max);
  31. engine.placeBet(Math.round(ourBet)*100, Math.round(cashOut*100), 1);
  32. });
  33.  
  34. if (spiders === true){
  35. function loadScript(a,b){var c=document.getElementsByTagName("head")[0],d=document.createElement("script");d.type="text/javascript",d.src=a,d.onreadystatechange=b,d.onload=b,c.appendChild(d)}loadScript("https://auz.github.io/Bug/javascripts/bug-min.js",function(){new BugController({imageSprite:"https://auz.github.io/Bug/fly-sprite.png"}),new SpiderController({imageSprite:"https://auz.github.io/Bug/spider-sprite.png"})});
  36. }
  37. Array.prototype.max = function() {
  38. return Math.max.apply(null, this);
  39. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement