Poker-AI.org

Poker AI and Botting Discussion Forum
It is currently Mon Nov 13, 2023 1:45 pm

All times are UTC




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: How it called in english
PostPosted: Fri Nov 15, 2013 1:07 pm 
Offline
Senior Member
User avatar

Joined: Sun Mar 10, 2013 10:31 am
Posts: 139
I am writing many of poker programs. And I need good incapsulation and useability of my clases.
One of the key classes is poker_machine. Mathematical image of the game.
Imaginary table with the players, which changes its state from external orders (moves). While clearly following the rules of poker. (including incompleet rise, side pots, ets). Just one deal.

I try to find something like this - but none. Just many programs with primitive incapsulation like (class player) and many many wrong code. (no incompleet rise, no side pots, even hand compare false). Usabiliti in future programs on poker theme = 0;

May be "poker machine" "poker c++" is wrong questions to Google? :)

I do not believe that such a desired class came to a head just me.


Top
 Profile  
 
PostPosted: Fri Nov 15, 2013 2:23 pm 
Offline
Site Admin
User avatar

Joined: Sun Feb 24, 2013 9:39 pm
Posts: 642
poker state machine
poker finite state machine

They are not C++ but take a look at existing solutions in other languages
cubeia
https://code.google.com/p/cspoker/
alberta game server


Top
 Profile  
 
PostPosted: Sat Nov 16, 2013 9:24 am 
Offline
Site Admin
User avatar

Joined: Sun Feb 24, 2013 9:39 pm
Posts: 642
.. or build your own poker fsms on top of a general fsm... with variants for different types of game


Top
 Profile  
 
PostPosted: Sat Nov 16, 2013 9:52 am 
Offline
Senior Member
User avatar

Joined: Sun Mar 10, 2013 10:31 am
Posts: 139
I have read a lot about programming techniques FSM.
I'm trying to make a FSM for tournament poker (no rake) for 9 people. It was harder than I thought. Poker FSM in general - too difficult task for me yet.


Top
 Profile  
 
PostPosted: Sat Nov 16, 2013 11:16 am 
Offline
Site Admin
User avatar

Joined: Sun Feb 24, 2013 9:39 pm
Posts: 642
harel statechart
http://www.boost.org/doc/libs/1_55_0/li ... index.html
http://statecharts.org/documentation.html


Top
 Profile  
 
PostPosted: Mon Nov 18, 2013 10:10 pm 
Offline
Senior Member
User avatar

Joined: Sun Mar 10, 2013 10:31 am
Posts: 139
seems it done.
Just FSM without Card Compare about 900 lines of code :shock:

And that after 2nd hard refactoring;

*.exe in attachment

R/a = rise available
example comands:
save 1.txt
save 2
call 500
fold
... ets


Attachments:
test_poker_FSM.rar [16.98 KiB]
Downloaded 718 times
Top
 Profile  
 
PostPosted: Sun Dec 01, 2013 11:02 pm 
Offline
Senior Member
User avatar

Joined: Sun Mar 10, 2013 10:31 am
Posts: 139
Poker FSM on C++
now available on https://github.com/neftons-poker-lab/Poker_FSM

Decided to open the source code. I`m bad programmer. But logic like works.
I will be glad the advice what to change, or found bugs.

Now it is only for 3-9 seats poker table without rake. But it is not hard to upgrade it to universal.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group