KgBC / just-dice-bot

Hi, this is a flexible betting bot for just-dice.com. Feel free to use it under GPL. If you want to donate some Beer/Satoshis: 1CDjWb7zupTfQihc6sMeDvPmUHkfeMhC83 Thanks. The ACES branch is considered stable, use this if you don't want to develop and do not need latest features: https://github.com/KgBC/just-dice-bot/tree/aces
GNU General Public License v2.0
18 stars 6 forks source link

Set a lowest balance to keep instead of broke #18

Closed geekium closed 10 years ago

geekium commented 10 years ago

Running the bot I can once reach to 20BTC from 10BTC, but without luck once I lose a time to the site, nothing left in my pocket! So, it's better set a targeted lowest balance to keep in the pocket so that it can run without care anymore. In this way it can make money more or less. P.S. I thought I had contribute about 0.3 BTC to author. Hopefully more to come with this feature implemented.

KgBC commented 10 years ago

hi, is planned. I don't really like the way I use safe_perc, I'll redefine that. Currently this balance is touched, but with low bets. In future I want this balance to be safe by default, and a command inside bot to ignore it if running on low balance.

Currently I implement another cool feature, this will be next.

p.s.: contribution isn't here, but would really, really help with development as I need a test balance. So if you can afford I have good use for it! :)

geekium commented 10 years ago

I jump into the just-dice-bot.py and found the code max_lose and max_bet, this would be helpful if it can config in the config.py . This should be an urgent issue 'cause I 've win 30BTC with a bold strategy but lost all the 30BTC because the bot bet an amount too high to suicide itself to death.

I mean, if I have 30BTC(balance) in my pocket, if I set a max_bet_perc to 10%,then the max_bet would be 3BTC if the bet multiplier reach larger than 3BTC, and then the strategy should change to bet the max_bet amount (in this case would be 3BTC) and bet X round with the bet_amount, the X round should be calculated from the chance parament, if the chance is 33% then bet 3 round with the max_bet, in theory should win 1 time, if 30% chance then the 3.3round goes to 4 round.

hope these feature won't be too complicated to implement. At least, the bot should be more configurable and offer more paratical strategy(ie. how many round with the chance). Thanks.

geekium commented 10 years ago

Just saw the new release with the loseX feature, it's another way to protect the pocket being gone wild to bet a insane amount. Good.

KgBC commented 10 years ago

Hi, I just test new code including your original feature request. It is using the safe_perc switch.

Example: you set safe_perc to 50 These 50% are calculated from the highest balance the bot sees, so if you start at 10 BTC, safe balance would be 5 BTC. If you win up to 20 BTC safe balance is 10 BTC. If you then lose again to e.g. 18 BTC the safe balance stays at 10 BTC.

New in the upcoming version is, the bot will not place a bet below safe balance. (before that release it was just betting slower). It seems to run fine, and I'll upload in some minutes.

To your post from 6h ago ... max_lose and max_bet are internal variables and couldn't be defined in config. Anyhow, I think what you wanted is already possible. But I need a bit more explanation:

If you dont want to discuss your strategy public feel free to contact me on TorChat: trxpncdbsaomdjgk (Download: https://github.com/prof7bit/TorChat/downloads)

KgBC commented 10 years ago

done. please update. safe_perc: percentage which will not be used in bets. bot is ending before using that balance.

I leave that open for the strategy question.