Post
Topic
Board Gambling discussion
Re: Seuntjie' Dice bot programmers mode discussion.
by
HCP
on 18/07/2019, 21:29:06 UTC
@Agent009

This script should do what you've asked... As always, it hasn't been extensively tested (I simply used the simulation and exported the results to check it), so use at your own risk!

You will need to modify the "edge" variable to match the "House Edge" of the site you want to play on... 1% HouseEdge = 1... 0.8% HE = 0.8 etc. Then set the basePayout and baseBet to suit your requirements. They are defaulted to 10x payout and 0.00000010 BTC

Code:
-------------------------------------------------------------------------------
--
-- Payout Martingalge Script for Agent009 by HCP
--
-- BTC Donations to: 33gzi64cvCr4i9ECGPwvZktzS2qknRUFhC
--
-------------------------------------------------------------------------------

edge       = 1 -- set to the house edge of your site
basePayout = 10 -- set to the base payout that you want
payout     = basePayout

chance     = (100 - edge) / payout -- calculate chance based on house edge
baseChance = chance

baseBet = 0.00000010 -- 1 "unit"
nextbet = baseBet -- set our initialBet

bethigh = false

function dobet()

    if win then
        -- reset to base bet/chance/payout
        nextbet = baseBet
        chance  = baseChance
        payout  = basePayout
       
    else
        -- increase payout
        payout  = payout + 1
       
        -- recalculate chance
        chance  = (100 - edge) / payout
       
        -- increase bet by 1 unit
        nextbet = previousbet + baseBet
    end

end