The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 2 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Texas Hold'em Poker
Author Message
RanXerox
Master
**

Posts: 550
Likes Given: 1
Likes Received: 12 in 9 posts
Joined: Dec 2010
Reputation: 19



Post: #1
Texas Hold'em Poker
Attached are a set of BETA scripts for a Texas Hold'em poker game... The basic system seems to be working, but I need a lot more people to use it and tell me about the bugs so I can fix them. When you submit a bug report, make sure you include the logging!

Here are some notes:

Quote:A running poker game is based on a specific in-game card ITEMDEF.
The state of the game is entirely stored as TAGs on this object and
in server VAR and LIST arrays related to that item by it's UID.
The game loop is based on the TIMER for the card item. To start a
game, just create the item and double-click it to join:

.add i_cards_poker

DEPENDENCIES:

This system depends on some generic functions, uncomment them at
the end of this file if you don't have them already in another
script. Specifically they are:

f_sizeof
f_getargv
f_clearglobals
f_ListToString

URGENT IMPROVEMENTS:

- FIX CUSTOM BETTING (currently commented out)
- PLAY TIMER (show countdown timer above the cards every 10 or 20 seconds)
- force a fold if players don't play in time (currently if a player chooses not to play, the game is stuck indefinitely)
- Implement proper 'who scores first' logic
- Implement side-pot calculations (currently there is no side-pot)

LONG TERM IMPROVEMENTS:

- unicode poker symbols (currently using letters for suits)
- add disclaimer click-through
- let table owner modify table limits
- player limits (currently 2-8)
- blind limits (currently 50/100)
- buyin amount (currently 5000-10000)
- the code has a 8 player max assumption (could be 10)
- allow for multiple table owners
- dynamic dialog element positions instead of DEFNAME based (i.e. origin)
- allow players to play simultaneous games (currently only one allowed)
- alternate table layouts
- tournament play (blinds increase over time)
- improved messages
- individual card names
- flop names
- hand names

LICENSE:

Most source code should be Free!
Code I have lawful authority over is and shall be!
Copyleft : This software is licensed under the GNU General Public
License (version 2), and as such comes with NO WARRANTY. Please
consult the Free Software Foundation (http://FSF.Org) for
important information about your freedom.

Here is a screenshot:

[Image: Poker.png?1341106984]

Updates:
07-11-2012 08:12 AM - Fixes for "f_getargv" bug.
07-14-2012, 01:10 PM - Fixes for "pot raise" bug.
07-14-2012, 02:15 PM - Fixes for "pot raise" bug (again).
07-15-2012, 03:42 PM - Other betting logic repairs.


Attached File(s)
.zip  poker.zip (Size: 78.91 KB / Downloads: 149)
(This post was last modified: 07-16-2012 07:43 AM by RanXerox.)
07-11-2012 12:21 PM
Find all posts by this user Like Post Quote this message in a reply
[+] 1 user Likes RanXerox's post
Alias
Journeyman
*

Posts: 107
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: Apr 2012
Reputation: 0



Post: #2
RE: Texas Hold'em Poker
Didnt work for me got error when poker start --> :ERROR:(Poker_CardFunctions.scp,48)Can't resolve <getargv 6 A,K,Q,J,T,9,8,7,6,5,4,3,2>
07-11-2012 09:23 PM
Find all posts by this user Like Post Quote this message in a reply
RanXerox
Master
**

Posts: 550
Likes Given: 1
Likes Received: 12 in 9 posts
Joined: Dec 2010
Reputation: 19



Post: #3
RE: Texas Hold'em Poker
I replaced all occurrences of getargv with f_getargv in the Poker_CardFunctions.scp file... you can do the same or you can download the new zip.
07-12-2012 12:12 AM
Find all posts by this user Like Post Quote this message in a reply
Alias
Journeyman
*

Posts: 107
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: Apr 2012
Reputation: 0



Post: #4
RE: Texas Hold'em Poker
(07-12-2012 12:12 AM)RanXerox Wrote:  I replaced all occurrences of getargv with f_getargv in the Poker_CardFunctions.scp file... you can do the same or you can download the new zip.
Ok ty i will try when i will be home
07-12-2012 12:28 AM
Find all posts by this user Like Post Quote this message in a reply
Alias
Journeyman
*

Posts: 107
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: Apr 2012
Reputation: 0



Post: #5
RE: Texas Hold'em Poker
Found bug, keep Pot Raising , even if you dont have money you still be able to raise pot ... here pic becouse my english isnt so good Big Grin
[Image: dqrykhgiyw34p4tyl1.jpg]
07-12-2012 09:59 PM
Find all posts by this user Like Post Quote this message in a reply
RanXerox
Master
**

Posts: 550
Likes Given: 1
Likes Received: 12 in 9 posts
Joined: Dec 2010
Reputation: 19



Post: #6
RE: Texas Hold'em Poker
LOL, ok I will fix that later today. thanks for your help.
07-12-2012 11:14 PM
Find all posts by this user Like Post Quote this message in a reply
Alias
Journeyman
*

Posts: 107
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: Apr 2012
Reputation: 0



Post: #7
RE: Texas Hold'em Poker
(07-12-2012 11:14 PM)RanXerox Wrote:  LOL, ok I will fix that later today. thanks for your help.
np Veryhappy
07-13-2012 12:15 AM
Find all posts by this user Like Post Quote this message in a reply
RanXerox
Master
**

Posts: 550
Likes Given: 1
Likes Received: 12 in 9 posts
Joined: Dec 2010
Reputation: 19



Post: #8
RE: Texas Hold'em Poker
I updated the zip file... the fix for this required fairly significant changes so you need to stop all running poker games, delete all existing i_cards_poker items, replace all the changed scp files, then resync.
07-15-2012 05:17 AM
Find all posts by this user Like Post Quote this message in a reply
Skul
Master
**

Posts: 413
Likes Given: 0
Likes Received: 19 in 15 posts
Joined: Jun 2012
Reputation: 9



Post: #9
RE: Texas Hold'em Poker
Just a suggestion, have you tried making a script to halt all poker games and delete all i_cards_poker? Maybe to make it easier for anyone updating as you progress this script?

"I ask a question to the answer I already know."

Marchadium :: http://www.marchadium.ca/ :: Join us!
07-15-2012 07:55 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
RanXerox
Master
**

Posts: 550
Likes Given: 1
Likes Received: 12 in 9 posts
Joined: Dec 2010
Reputation: 19



Post: #10
RE: Texas Hold'em Poker
Good idea... especially since there will be another patch coming soon because my previous one didn't solve all the over-betting problems ;-)
07-15-2012 08:03 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)