Hello Guest

Need a simple solution

  • 1 Replies
  • 100 Views
*

DarkMatrix

  • *
  • 1
  • +0/-0
    • View Profile
Need a simple solution
« on: September 02, 2021, 02:21:44 pm »
How do i add reset after 200 wins  fucntion in this script??
Site Stake.com


Code: [Select]
chance  = 90
bethigh = true
basebet = balance/25000
nextbet = basebet

function dobet()
    if (win) then
        print("This is fun")
        chance  = 90
        nextbet = balance/25000
    else
        print("Okay. We need more wins")
        chance  = 85
        nextbet = previousbet * 7
        end
    end
end

*

GodAscorbin

  • **
  • 13
  • +0/-0
    • View Profile
Re: Need a simple solution
« Reply #1 on: September 22, 2021, 01:25:08 pm »
hello,
i would add a variable that counts the wins.
and then reset when it reaches 200, and set to 0 again.
like this:

chance  = 90
bethigh = true
basebet = balance/25000
nextbet = basebet
wincount = 0

function dobet()
    if (win) then
        wincount = wincount +1
       if wincount > 199 then
        resetseed()
        resetstats()
        wincount = 0
      end

        print("This is fun")
        chance  = 90
        nextbet = balance/25000

    else
        print("Okay. We need more wins")
        chance  = 85
        nextbet = previousbet * 7
        end
    end
end