Last active
April 25, 2020 10:59
-
-
Save mydicebot/4c020861fa01ed5bdba491ab3cf27543 to your computer and use it in GitHub Desktop.
Demo of start() #mydicebot#
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
chance = 1 | |
multiplier = 2 | |
basebet = 0.00000001 | |
bethigh = false | |
nextbet = basebet | |
my_variable = 1 | |
function sleep(n) | |
t0 = os.clock() | |
while os.clock() - t0 <= n do end | |
end | |
function dobet() | |
print('chance is ' .. tostring(chance)) | |
print('my_variable is ' .. tostring(my_variable)) | |
if(chance == 3) then | |
stop() | |
print('chance is ' .. tostring(chance) .. ', so start from beginning again.') | |
start() | |
end | |
chance = chance + 1 | |
my_variable = my_variable + 1 | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment