resetstats()
resetseed()
minbet = 1e-8
nextbet = minbet
perte = 0
payout= 1
sensM = true
WageredB = 0
ProfitB = 0
div = 1
--balance=10000 --simu
mdBourrin = false --false=safe true = risky
casino= 1 --% edge house
chance= 9.9 --base chance
chanceMin = 1 --chance minimum
bb= 1e-7/div -- base bet (1/div = 1 satoshi)
target= balance*2 --STOP_IF_BALANCE_OVER target
limite= 0 --STOP_IF_BALANCE_UNDER limite
-----------------------
chanceDB = chance
bbDB = bb
function simu_printInfo()
print("wagered= " ..wagered)
print("profit= " ..profit)
print("PERF= " ..(wagered/profit)*100 .."%")
print ("chance= " ..chance)
print("nextbet= " ..nextbet .." N° " ..bets)
end
nextbet=bb
function getmulti()
payout=(100-1)/chance
return payout/(payout-1)
end
slf = 0.75
sl = balance * slf
ath = 0
halt = 1.1e-1
function dobet()
if balance>=halt then
stop()
ching()
end
bb = balance/1e5
if balance > ath then
ath = balance
sl = balance * slf
end
if balance < sl then
log(" Stop loss")
stop()
end
WageredB +=lastBet.amount
ProfitB +=currentprofit
perte +=currentprofit
if win then
bethigh = math.random(0,100)%2==0
chance = lastBet.roll
bb = bb*getmulti()/1e3
if bb<1e-8 then bb=1e-8 end
payout = 1
else
if sensM==true then
payout +=1
else
payout -= 1
end
end
--[[if bets%50==0 then
if perte < 0 then
nextbet = previousbet*2
end
end--]]
chance = (100-casino)/payout
if chance >= chanceDB then
chance = chanceDB
sensM=true
end
if chance <= chanceMin then
chance = chanceMin
sensM=false
end
payout = (100-casino)/chance
if mdBourrin == false then
nextbet = (-perte+bb)/(payout-1)
else
nextbet = (WageredB-ProfitB+bb)/(payout-1)
end
if nextbet <= bb then
nextbet = bb
end
if perte >= 0 then
perte = 0
nextbet = bb
end
end