Agent009
Newbie
Offline
Activity: 46
Merit: 0
|
 |
July 19, 2019, 12:50:15 AM |
|
@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 ------------------------------------------------------------------------------- -- -- 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
HCP thank you very much!  I will test it today and then talk about the results...
|
|
|
|
|
sleepyeyed
Newbie
Offline
Activity: 23
Merit: 1
|
 |
July 31, 2019, 04:47:31 PM |
|
How can I calculate the probability of rolls if I start at chance=1 and keep increasing the chance by 1 on each loss? What would be the probability that it would reach chance=90? also, how would I increase each bet on loss so that it would stay in profit or at least break even? In my code below I'm toying with using exponents, but I'm just throwing random numbers at it to see what sticks so far. basebet=1 nextbet=basebet chance=1 function dobet()
if win then nextbet=basebet chance=1 end
if !win then chance=chance+1 nextbet=previousbet*1.165^1.75 end
|
|
|
|
seuntjie
Legendary
Offline
Activity: 1717
Merit: 1125
|
 |
August 01, 2019, 07:19:30 AM |
|
How can I calculate the probability of rolls if I start at chance=1 and keep increasing the chance by 1 on each loss? What would be the probability that it would reach chance=90? also, how would I increase each bet on loss so that it would stay in profit or at least break even? In my code below I'm toying with using exponents, but I'm just throwing random numbers at it to see what sticks so far. basebet=1 nextbet=basebet chance=1 function dobet()
if win then nextbet=basebet chance=1 end
if !win then chance=chance+1 nextbet=previousbet*1.165^1.75 end
Not sure about the probability, my stats isn't that good. How to calculate the next bet to ensure you break even: You will need to track your streak profit. to do this, have a variable that you add your losses to when you lose and reset when you win. Then you can use the formulas payout=(100-edge)/chance and profit=(betamount*payout)-betamount to calculate what your bet amount should be so if you've had 30 losses in a row and you have, say, -35 profit for the losing streak, you can calculate your next bet to break even using -(streakprofit) = (x * ((100- site.edge)/chance))-x refactors to x= -(streakprofit)/payout (this assumes streakprofit is negative)
|
|
|
|
sleepyeyed
Newbie
Offline
Activity: 23
Merit: 1
|
 |
August 01, 2019, 12:04:09 PM |
|
Not sure about the probability, my stats isn't that good.
How to calculate the next bet to ensure you break even: You will need to track your streak profit. to do this, have a variable that you add your losses to when you lose and reset when you win. Then you can use the formulas payout=(100-edge)/chance and profit=(betamount*payout)-betamount to calculate what your bet amount should be
so if you've had 30 losses in a row and you have, say, -35 profit for the losing streak, you can calculate your next bet to break even using
-(streakprofit) = (x * ((100- site.edge)/chance))-x refactors to x= -(streakprofit)/payout (this assumes streakprofit is negative)
I kind of understand this, but am unsure of how I can fit this into my code so that it works correctly. So does the x variable represent my next bet? Sorry for my programming logic ignorance. I'll try my best at wrapping my head around it for now.
|
|
|
|
docthusinh
Jr. Member
Offline
Activity: 225
Merit: 4
|
 |
September 06, 2019, 03:38:05 PM |
|
Not sure if the programming mode support this:
betsides = [L, H, L, L, H, L, H, H, L, L....] stakes = [1, 1, 1, 2, 3,4, 5, 6...] betodds = [2, 2, 2, 3, 4, 5, ....]
if win nextside = betsides[0] nextstake = stakes[0] nextodd = betodds[0]
else //lose nextside = betsides[currentstreak] nextstake = stakes[currentstreak] nextodd = betodds[currentstreak]
Questions are: 1) Will above variables taken for use in the bot (nextside, nextstake, nextodd)? If not, how to implement above? 2) Is the first lose will cause currentstreak = 1? 3) If above array list suported, what is the maximum size? Basically I need 3000+
|
|
|
|
seuntjie
Legendary
Offline
Activity: 1717
Merit: 1125
|
 |
September 07, 2019, 07:26:21 PM |
|
Not sure if the programming mode support this:
betsides = [L, H, L, L, H, L, H, H, L, L....] stakes = [1, 1, 1, 2, 3,4, 5, 6...] betodds = [2, 2, 2, 3, 4, 5, ....]
if win nextside = betsides[0] nextstake = stakes[0] nextodd = betodds[0]
else //lose nextside = betsides[currentstreak] nextstake = stakes[currentstreak] nextodd = betodds[currentstreak]
Questions are: 1) Will above variables taken for use in the bot (nextside, nextstake, nextodd)? If not, how to implement above? 2) Is the first lose will cause currentstreak = 1? 3) If above array list suported, what is the maximum size? Basically I need 3000+
1+3) https://www.lua.org/pil/11.1.html2) See the tutorials on https://forum.seuntjie.com/index.php?topic=2.0, specifically https://steemit.com/dicebot/@seuntjie/dicebot-programmer-mode-tutorial-1-1-variablesAlso, see just a quick tutorial/example for if statements regarding if statements in LUA.
|
|
|
|
sleepyeyed
Newbie
Offline
Activity: 23
Merit: 1
|
 |
September 20, 2019, 05:49:44 PM Last edit: September 20, 2019, 07:24:02 PM by sleepyeyed |
|
Is there any way to round numbers off easily? For instance if I have the following code... basebet=.00000001 chance=89 function dobet()
if win then chance=chance/2 nextbet=basebet end
Since the chance on a win will be split in half then the chance would be 44.5. What if I wanted to round the chance to the next higher whole chance being 46? is there a simple way to do this?
|
|
|
|
HCP
Legendary
Offline
Activity: 2086
Merit: 4369
<insert witty quote here>
|
 |
September 20, 2019, 10:31:30 PM |
|
Is there any way to round numbers off easily?
There are math.floor() and math.ceil() functions in LUA (the scripting language of the dice bot), that will allow you to "round" to whole numbers... However, they don't do typical ".5" rounding... They just go up or down to the next whole number, regardless of the decimal. So, math.floor(4.8 ) will result in 4... and math.ceil(4.1) will result in 5. One trick to "fix" this and have more "normal" rounding, is to simply add 0.5 and use math.floor(): x = 4.3 y = 4.8 z = 4.5
print("Normal Rounding") print("x: ",x," --> ", math.floor(x+0.5)) print("y: ",y," --> ", math.floor(y+0.5)) print("z: ",z," --> ", math.floor(z+0.5))
would yield: Normal Rounding x: 4.3 --> 4 y: 4.8 --> 5 z: 4.5 --> 5
In your example: chance=89 print("chance: ",chance) chance = chance / 2 print("chance BEFORE: ",chance) chance = math.floor( chance + 0.5) print("chance AFTER: ",chance)
would result in this output: chance: 89 chance BEFORE: 44.5 chance AFTER: 45
Hope that helps.
|
|
|
|
houseworx
|
 |
September 21, 2019, 12:00:11 PM |
|
how I can simple make something:
if currentstreak "every number" then do something end
11111222223333344444
for example every 5 streak next 5 streak made nextbet = previousbet + 0.00000001
I dont understand, last period when bot was updates with this "blue words" in code box, they dont like = simbol.
'then' expected, got '='
|
|
|
|
Phyzyprogrammer
Member

Offline
Activity: 90
Merit: 10
Visit www.btcscriptbot.wordpress.com to get latest
|
 |
September 27, 2019, 09:26:28 AM |
|
I need a Good programmer, that can help me create a script for bitsler Gambling site, I have a personal strategy that I use, and I want to create a script for it, so I can just past the script on my browser console option and start betting automatically!, I will pay you...... So pls reply to this post let me know how good you are, thank you guys
|
visit ( www.btcscriptbot.wordpress.com) we offer latest scripts and bots to earn bitcoins and other altcoins for free and paid! Earn Bitcoins with bots
|
|
|
seuntjie
Legendary
Offline
Activity: 1717
Merit: 1125
|
 |
September 27, 2019, 10:53:12 AM |
|
This thread is for the programmer mode in DiceBot, NOT console scripts that you run in your browser. I would not recommend using anything that runs in your browser console.
|
|
|
|
HCP
Legendary
Offline
Activity: 2086
Merit: 4369
<insert witty quote here>
|
 |
September 28, 2019, 03:46:28 AM |
|
how I can simple make something:
if currentstreak "every number" then do something end
11111222223333344444
for example every 5 streak next 5 streak made nextbet = previousbet + 0.00000001
Do you mean every 5 loss streak? 5 win streak? or something else? Personally, I would do something like: myLossStreakCounter = 0 streakLimit = 5
function dobet() ... if (!win) then -- If it was a loss, increment the counter myLossStreakCounter = myLossStreakCounter + 1 end ... if myLossStreakCounter == streakLimit then -- reached the streak limit, increase bet and reset counter nextbet = previousbet + 0.00000001 myLossStreakCounter = 0 end ...
If should be relatively obvious how the code can be modified to be used for a Win streak I dont understand, last period when bot was updates with this "blue words" in code box, they dont like = simbol.
'then' expected, got '='
This error suggests that you have a syntax error in your code. The bot thinks you're trying to use an "if something then" command, but it can't find the "then" part of the command before it finds an "=". Usually it shows a line number where the error occurred. Check near there for incorrect code... failing that, you'd need to post the code for others to be able to debug it properly.
|
|
|
|
sleepyeyed
Newbie
Offline
Activity: 23
Merit: 1
|
 |
October 02, 2019, 03:09:34 PM |
|
I'm playing with the idea of incrementally increasing my bet based on my balance and as the balance increases the increment of the bet gets smaller. In the code below I have this working, but I'm thinking that there must be an easier or shorter way to do this with variables. If anyone has any suggestions I'd appreciate it. basebet=.00000001
if balance>.00025000 and balance<.00150000 then basebet = balance/25000 end
if balance>=.00150000 and balance<.00300000 then basebet = (balance/50000)+.00000003 end
if balance>=.00300000 and balance<.00600000 then basebet = (balance/100000)+.00000006 end
if balance>=.00600000 and balance<.01000000 then basebet = (balance/200000)+.00000009 end
if balance>=.01000000 then basebet = (balance/500000)+.00000012 end
|
|
|
|
HCP
Legendary
Offline
Activity: 2086
Merit: 4369
<insert witty quote here>
|
 |
October 02, 2019, 10:45:23 PM |
|
I'm playing with the idea of incrementally increasing my bet based on my balance and as the balance increases the increment of the bet gets smaller. In the code below I have this working, but I'm thinking that there must be an easier or shorter way to do this with variables. If anyone has any suggestions I'd appreciate it.
About all you can do in this scenario is refactor your code slightly to avoid the script having to process every individual "if" statement by using "elseif's"... once it finds the "matching" elseif, it will drop out of the if and move on: if balance < 0.00025000 then basebet = 0.00000001 elseif balance < 0.00150000 then basebet = (balance / 25000) elseif balance < 0.00300000 then basebet = (balance / 50000) + 0.00000003 elseif balance < 0.00600000 then basebet = (balance / 100000) + 0.00000006 elseif balance < 0.01000000 then basebet = (balance / 200000) + 0.00000009 else basebet = (balance / 500000) + 0.00000012 end
As for using variables, I don't think that it would be "easier" or "shorter"... as you have several factors in play (ie. the divisor and the increment) which need to be modified for each "step" in your system. Potentially you could set up some arrays to hold these, like: divisor = {25000,50000,100000,200000,50000} increment = {0,0.00000003,0.00000006,0.00000009,0.00000012}
basebet = (balance / divisor[x]) + increment[x]
But then you're still left with trying to derive the index into those arrays... and then it gets a bit more complicated... like this: step = 1 bal = {0.00025, 0.0015, 0.003, 0.006, 0.01, 999999999} divider = {1, 25000, 50000, 100000, 200000, 500000} increment = {0, 0, 0.00000003, 0.00000006, 0.00000009, 0.00000012}
while bal[step] < balance do step = step + 1 end
if step == 1 then basebet = 0.00000001 else basebet = (balance / divider[step]) + increment[step] end
NOTE: This code appears to work... but I haven't tested it in the bot.
|
|
|
|
houseworx
|
 |
October 06, 2019, 08:43:34 AM |
|
how I can simple make something:
if currentstreak "every number" then do something end
11111222223333344444
for example every 5 streak next 5 streak made nextbet = previousbet + 0.00000001
Do you mean every 5 loss streak? 5 win streak? or something else? Personally, I would do something like: myLossStreakCounter = 0 streakLimit = 5
function dobet() ... if (!win) then -- If it was a loss, increment the counter myLossStreakCounter = myLossStreakCounter + 1 end ... if myLossStreakCounter == streakLimit then -- reached the streak limit, increase bet and reset counter nextbet = previousbet + 0.00000001 myLossStreakCounter = 0 end ...
If should be relatively obvious how the code can be modified to be used for a Win streak I dont understand, last period when bot was updates with this "blue words" in code box, they dont like = simbol.
'then' expected, got '='
This error suggests that you have a syntax error in your code. The bot thinks you're trying to use an "if something then" command, but it can't find the "then" part of the command before it finds an "=". Usually it shows a line number where the error occurred. Check near there for incorrect code... failing that, you'd need to post the code for others to be able to debug it properly. thanks!
|
|
|
|
houseworx
|
 |
October 06, 2019, 08:46:56 AM |
|
btw Seuntjie, what kind of "built-in variable" do not working at simulation?! i know there is something wrong. like example simulation dont use "profit from stats statesment" you need to write manual "own roundprofit" to use that kind of things, but what else?! simulation using "currentstreak"? etc or everthing are need to be written by "own"?!
my target is to say, simulation dont use currentstreak right or not at all in it, can be?!
|
|
|
|
seuntjie
Legendary
Offline
Activity: 1717
Merit: 1125
|
 |
October 08, 2019, 07:44:28 AM |
|
btw Seuntjie, what kind of "built-in variable" do not working at simulation?! i know there is something wrong. like example simulation dont use "profit from stats statesment" you need to write manual "own roundprofit" to use that kind of things, but what else?! simulation using "currentstreak"? etc or everthing are need to be written by "own"?!
my target is to say, simulation dont use currentstreak right or not at all in it, can be?!
All internal variables should be available in the simulations.
|
|
|
|
best_coins_com
Newbie
Offline
Activity: 10
Merit: 0
|
 |
October 27, 2019, 11:44:46 PM |
|
Hello.
I want to ask if you can add to bot (Im interested in website freebitco.in) sth like array with Hi Low options?
I mean i want to make autobet for example: hi, hi, low, hi, low, low, low, hi, low which will be fully random. I have my own strategy.
Is it possible?
Thanks
|
|
|
|
seuntjie
Legendary
Offline
Activity: 1717
Merit: 1125
|
 |
October 29, 2019, 08:30:03 AM |
|
Hello.
I want to ask if you can add to bot (Im interested in website freebitco.in) sth like array with Hi Low options?
I mean i want to make autobet for example: hi, hi, low, hi, low, low, low, hi, low which will be fully random. I have my own strategy.
Is it possible?
Thanks
If you want to use random high/low, you don't need to use an array. Here's a sample script that bets a random amount at a random chance with random high/low: https://bot.seuntjie.com/scripts.aspx?id=18Take out the part that you need, be sure to read through the tutorials if you're not familiar with programming: https://bot.seuntjie.com/ProgrammerMode.aspx
|
|
|
|
|