I tried this
nextbet=basebet
resetstats();
resetseed();
end
It resets the stats but it keeps going with the same bet, the nextbet doesn't return to basebet. (I have basebet variable determined)
Please help me out, thanks!
can you post your whole script and explain what your'e trying to do?
Thanks for replying!
This is the whole script - Pluscoup by chilly2k and grendel25 (I got it from your website).
nextbet = basebet
roundprofit = 0
chance = 49.5
minbal=balance-0.0300000
maxbal=balance+0.01500000
function dobet()
roundprofit += currentprofit
if (win) then
if (roundprofit < 0) then
nextbet = previousbet + basebet
print ("WIN")
print(nextbet)
else
nextbet = basebet
print ("WIN")
print(nextbet)
end
if balance
end
if balance>maxbal then
stop()
end
if roundprofit > 0 then roundprofit = 0 end
end
if (!win) then
nextbet = previousbet
print ("LOSE")
print(nextbet)
end
end
if balance
end
if balance>maxbal then
stop()
end
end
end
What I am trying to do is this: when the profit (not whole account profit, just the session before resetstats) goes lower than 0.0005 for example, at fist I wanted the bot to stop and then restart but you told me it's not possible, so now I want it to reset the bet to basebet and also resetstats.
I tried with this:
nextbet=basebet
resetstats();
end
... and it's not workin, it resets the stats but the bet doesn't go to basebet, it stays where it was.
Thanks for your time and I hope we figure it out!
Your not saying/showing where you put that code. If you put it just before the last end statement, I think it should work.
If you were trying it at the top, nextbet would get reset further in the code.
Just for educational purposes, the last end statement close the dobet() function.
I tried placing the code at the end of the script, right before the last end that closes the dobet function and now it doesn't even resets the stats like it used to... it just keeps going like the code it's not even there.
This is my whole script exactly as I use it in the bot (the only things I added to it are the two IFs at the very end):
nextbet = basebet
roundprofit = 0
chance = 50
minbal=balance-0.0300000
maxbal=balance+0.01500000
function dobet()
roundprofit += currentprofit
if (win) then
if (roundprofit < 0) then
nextbet = previousbet + basebet
print ("WIN")
print(nextbet)
else
nextbet = basebet
print ("WIN")
print(nextbet)
end
if balance
end
if balance>maxbal then
stop()
end
if roundprofit > 0 then roundprofit = 0 end
end
if (!win) then
nextbet = previousbet
print ("LOSE")
print(nextbet)
end
end
if balance
end
if balance>maxbal then
stop()
end
end
if profit <= -0.0001000 then
nextbet=basebet
resetstats()
end
if profit >= 0.001 then
withdraw(profit,'BTC ADDRESS')
nextbet=basebet
resetstats()
end
end
Try this. I think there were to many end statements. I formatted it a little better to match up if's and ends. I don't have the bot available on my new computer, otherwise I would have tested it out.
nextbet = basebet
roundprofit = 0
chance = 50
minbal=balance-0.0300000
maxbal=balance+0.01500000
function dobet()
roundprofit += currentprofit
if (win) then
if (roundprofit < 0) then
nextbet = previousbet + basebet
print ("WIN")
print(nextbet)
else
nextbet = basebet
print ("WIN")
print(nextbet)
end
if balance
end
if balance>maxbal then
stop()
end
if roundprofit > 0 then roundprofit = 0 end
end
if (!win) then
nextbet = previousbet
print ("LOSE")
print(nextbet)
end
if balance
end
if balance>maxbal then
stop()
end
if profit <= -0.0001000 then
nextbet=basebet
resetstats()
end
if profit >= 0.001 then
withdraw(profit,'BTC ADDRESS')
nextbet=basebet
resetstats()
end
end
Thank you very much mate!! That seems to be working just fine right now, thanks a lot again for your time!