Welcome, Guest. Please login or register.
December 01, 2021, 10:12:32 AM
Home Help Login Register
News:

Shanky Technologies Poker Bot Support Forum  |  General Category  |  PPL Support (Moderator: sngbot)  |  Topic: Help With A Few Code Lines 0 Members and 1 Guest are viewing this topic.
Pages: [1] Print
Author Topic: Help With A Few Code Lines  (Read 747 times)
DocPoker16
zeros
*

Karma: 0
Posts: 5


« on: September 07, 2021, 12:03:29 AM »

The model I am attempting to implement is geared toward LIMIT Holdem and seems to consist of 6 main variables which are
1. The odds/percentages of winning the hand im holding in relation to the number of players in the hand
2. the amount of the bet to call to stay in the hand
3. the size of the pot
4. the ratio between the amount to bet vs. the pot size (in terms of odds or percentages)
5. whether the odds of the pot is greater or lesser than the odds of the bet size
6. whether to check, call, raise or fold after all the mentioned information has been taken into account

this is the main premise

I'm sure this must be done pre flop, flop, turn and river, as the odds and number of players will vary at each level

an example might be as follows. When holding a flush draw after the turn, the odds of filling the hand is 4.1 to 1 or 19.6%

(I.E. 9 successful cards out of 46 remaining). If pot size is greater than 4.1 to 1 or 19.6% of bet = CALL. If pot size is equal to or less than 4.1 to 1= FOLD.

Basically if the odds of winning the hand is greater than the ratio of the bet size to pot size, then FOLD. If less, then CALL

I believe the number of players in the hand should be factored because the odds of winning varies according to number of players. In other words, the odds of MAKING your hand varies by the number of players. There is definitely a distinction between making and filling the hand and winning the hand and i'm sure a good code will work this out properly. It seems that the odds of winning the hand has more weight than filling the hand. For example, The odds of improving pocket AA are always static in all circumstances, where the odds of WINNING with those pocket AA varies according to the number of players.

I very much hope that the way I attempted to explain this makes sense as I am not a coding expert. I am very sure that your program would satisfy the criteria involved. I have heard very favorable comments about your program. You have done great work.

Very Best Regards
Logged
Egor
Forum Admin
Extreme Botter
*****

Karma: 371
Posts: 34342



WWW
« Reply #1 on: September 07, 2021, 12:14:13 AM »

I'm sure I can help. I will leave figuring out what odds you want on which types of drawing boards to you. So give me a situation here and I will write you a codeline to help you get the feel of how this is done.

You mentioned a situation with (what I assume is) a pure flush draw on the Turn. Assuming the board is not paired and a flush is not already possible, to tell the bot to call a bet from an opponent would look like:


When not (flushpossible or paironboard) and haveflushdraw and bets = 1 and raises = 0 and amounttocall <= 19% potsize call force


Obviously you also need to code for raises, acting last when checked to (if you want to bet sometimes), boards with a pair, and perhaps when there are 3+ live opponents and your flush draw is really low meaning a bigger flush draw coukd be out.
Logged

Please do not PM me about license issues or help stuff - email me or use the Help board. Thanks! -Egor
DocPoker16
zeros
*

Karma: 0
Posts: 5


« Reply #2 on: September 07, 2021, 01:55:41 AM »

what is the proper way to code when im holding KK preflop there are a total of 5 players in the hand including me and the bet is $10 to call and the potsize is $40 and we want to raise $10


Also what is the proper way to code when im holding 7 2 off suit fold pre flop    just making sure im coding these right
Logged
DocPoker16
zeros
*

Karma: 0
Posts: 5


« Reply #3 on: September 07, 2021, 02:01:04 AM »

Another example I am holding JQ Suited (clubs) Flop is 3H 7C 8C turn is KD we have a flush draw the bet to me is $20 the pot has $60 if the pot is equal or less than 33% FOLD if the pot is greater than 33% call
Logged
tapthatace
Botter
***

Karma: 7
Posts: 202


« Reply #4 on: September 07, 2021, 03:44:37 AM »

what is the proper way to code when im holding KK preflop there are a total of 5 players in the hand including me and the bet is $10 to call and the potsize is $40 and we want to raise $10


Also what is the proper way to code when im holding 7 2 off suit fold pre flop    just making sure im coding these right


Your first situation you are providing a lot of information which might not be relevant.  So you would need to answer a few questions --- Does number of Opponents matter, does the potsize mean anything in regards to raise, == if you have KK pre will you raise no matter what?  If so it would be like this:

When hand = KK Raise force

When Hand = 72 and not (hand=72 suited) Fold Force
« Last Edit: September 07, 2021, 04:00:01 AM by Egor » Logged
tapthatace
Botter
***

Karma: 7
Posts: 202


« Reply #5 on: September 07, 2021, 03:50:18 AM »

Another example I am holding JQ Suited (clubs) Flop is 3H 7C 8C turn is KD we have a flush draw the bet to me is $20 the pot has $60 if the pot is equal or less than 33% FOLD if the pot is greater than 33% call

When HaveFlushDraw and AmountToCall >= 33% PotSize Call Force

The last line of your turn code can then be (this will fold anything you don't have code for which will reduce the number of lines you need to have in your project):

When others Fold Force
Logged
Egor
Forum Admin
Extreme Botter
*****

Karma: 371
Posts: 34342



WWW
« Reply #6 on: September 07, 2021, 04:07:12 AM »

Quote
what is the proper way to code when im holding KK preflop there are a total of 5 players in the hand including me and the bet is $10 to call and the potsize is $40 and we want to raise $10

You need to narrow down the situation as much as possible. I mean, you are going to raise with KK in more situations than this, right? Also, didn't you say this was for fixed limit holdem? In which case you don't even need to concern yourself with "how much" you are raising. If you are always going to raise with KK no matter what then just say:

when hand = KK raise force

Quote
Another example I am holding JQ Suited (clubs) Flop is 3H 7C 8C turn is KD we have a flush draw the bet to me is $20 the pot has $60 if the pot is equal or less than 33% FOLD if the pot is greater than 33% call

when have2ndnutflushdraw and bets = 1 and raises = 0 and not (flushpossible or straightpossible or paironboard) and amounttocall <= 32% potsize call force

there are other things you can add to it, such as board = K and not (board = A)
« Last Edit: September 07, 2021, 07:23:12 AM by Egor » Logged

Please do not PM me about license issues or help stuff - email me or use the Help board. Thanks! -Egor
Egor
Forum Admin
Extreme Botter
*****

Karma: 371
Posts: 34342



WWW
« Reply #7 on: September 07, 2021, 07:50:25 PM »

Another idea I have is that you seem to be making a very basic fixed-limit profile that will take some time and work to create. Instead you might consider purchasing "Tensor" from the marketplace and just go through and edit that to your liking, adjusting the % to where you want for pot odds and such, and then post any plays here that you don't like and I can help you create new codelines to tweak those plays and insert at the top of the betting round to override.

Just an idea that will save you a lot of time and reinventing the wheel...
Logged

Please do not PM me about license issues or help stuff - email me or use the Help board. Thanks! -Egor
DocPoker16
zeros
*

Karma: 0
Posts: 5


« Reply #8 on: September 08, 2021, 10:27:30 PM »

Thanks, does tensor include the amounttocall in relation to pot size on every hand?
Logged
DocPoker16
zeros
*

Karma: 0
Posts: 5


« Reply #9 on: September 08, 2021, 10:33:15 PM »

Also does it include variable about the amount of players in the hand or will I have to put those in as well
Logged
Egor
Forum Admin
Extreme Botter
*****

Karma: 371
Posts: 34342



WWW
« Reply #10 on: September 08, 2021, 11:31:40 PM »

I don't know. I have never seen it. But being as it is for fixed limit and has some good feedback I assume it at least has a reasonable framework to start from.

On the other hand you do seem to want a certain control of the structure in which case you may be happier designing the structure yourself.

When coding post-flop I think it is easiest to use open-ended codeblocks which define the board state. For example:

turn

When flushpossible and not (paironboard or suitsonboard =1 or flushpossibleonflop)
  when havenutflush raise force
  when haveflush and bets = 0 and raises = 0 bet force
  when haveflush and raises >= 1 call force
  when (havestraight or havetwopair) and bets = 0 and raises = 0 bet force
  when haveset and raises = 0 raise force
  when haveset call force
  when havenutflushdraw call force
Logged

Please do not PM me about license issues or help stuff - email me or use the Help board. Thanks! -Egor
Pages: [1] Print 
Shanky Technologies Poker Bot Support Forum  |  General Category  |  PPL Support (Moderator: sngbot)  |  Topic: Help With A Few Code Lines
Jump to:  


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!