Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function randomnum(min,max){
- return Math.floor(Math.random()*(Math.floor(max)-Math.floor(min)+1))+Math.floor(min);
- }
- function resetseed(){
- var a=document.getElementsByClassName('ManualSeedControls')[0];
- if(!a)return;
- if(a.style.display!='block'){
- console.log('Enabling manual seed');
- if(document.getElementById('AccountTabManualSeed')){
- document.getElementById('AccountTabManualSeed').click();
- }
- resetseed();
- }
- else{
- var b=a.getElementsByTagName('input')[0];
- if(b){
- b.value=randomnum(0,999999999);
- console.log('Seed changed: '+b.value);
- }
- }
- }
- function readbalance(){
- return Number(document.getElementsByClassName('UserBalance')[0].innerHTML);
- }
- function checkchange(){
- var a=document.getElementById('LastBetInfoProfit');
- var b=document.getElementById('LastBetInfoSecret');
- if(!a || !b)return false;
- if(Number(b.innerHTML)!==safe[0] || Number(a.innerHTML)!==safe[1]){
- safe=[Number(b.innerHTML),Number(a.innerHTML)];
- return true;
- }
- return false;
- }
- function checkwin(){
- if(!checkchange())return 'unchanged';
- var a=Number(document.getElementById('LastBetInfoProfit').innerHTML);
- var b=Number(document.getElementById('LastBetInfoSecret').innerHTML);
- return a>0?true:(a<0?false:'error');
- }
- function timestamp(){
- return Math.round(Date.now()/1000);
- }
- function dobet(){
- var t=document.getElementById("startstop");
- if(betting && t.value=='Start betting')t.value='Stop betting';
- else if(!betting && t.value=='Stop betting')t.value='Start betting';
- if(!betting)return;
- readbalance();
- win=checkwin();
- if(safe[0]!==0 && safe[1]!==0 && (win==='error' || win=='unchanged'))return;
- console.log('Win: '+win);
- if(win===false){ //lose
- kik++;
- resetseed();
- }
- else kik=0;
- if(kik>1)nextbet=previousbet*2;
- else nextbet=basebet;
- if(nextbet==previousbet*2)lol++;
- if(lol>=3)nextbet=previousbet;
- if(balance<=more/2)nextbet=previousbet*2.1;
- if(nextbet==previousbet*2.1){
- fuck++;
- if(fuck>1)nextbet=previousbet;
- }
- if(balance>more && a){
- nextbet=basebet;
- lol=0;
- more=balance;
- }
- if(balance<target){
- console.log('Balance: '+balance+' - Basebet: '+basebet+' ['+chance+'%] - Previousbet: '+previousbet+' - Nextbet: '+nextbet);
- document.getElementById('BetSizeInput').value=nextbet;
- document.getElementById('BetChanceInput').value=chance;
- document.getElementById('BetLowButton').click();
- }
- else{
- console.log('Target reached ('+target+')');
- betting=false;
- }
- }
- document.getElementById("ChatTabOtherRooms").innerHTML='<input id="startstop" type="button" onclick="betting=!betting;" value="Start betting">';
- var delay=1.5;//seconds
- var balance=readbalance();
- var chance=49.95;
- var kik=0;
- var fraction=100;
- var target=10000; //fixed amount
- var basebet=balance/fraction;
- var nextbet=basebet;
- var previousbet=basebet;
- var more=balance;
- var lol=0;
- var fuck=0;
- var time0=timestamp();
- var time1=time0;
- var win=false;
- var safe=[0,0]; //don't touch this
- var betting=false;
- setInterval(dobet,delay*1000);
Add Comment
Please, Sign In to add comment