<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/4384" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2003-05-15T07:10:40-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/4384</id>

		<entry>
		<author><name><![CDATA[arcane]]></name></author>
		<updated>2003-05-15T07:10:40-04:00</updated>

		<published>2003-05-15T07:10:40-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=20213#p20213</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=20213#p20213"/>
		<title type="html"><![CDATA[TCL Poker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=20213#p20213"><![CDATA[
hehe... sounds interesting...<br>sounds like my next project when avote2 is finished <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2617">arcane</a> — Thu May 15, 2003 7:10 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[stdragon]]></name></author>
		<updated>2003-05-14T01:43:13-04:00</updated>

		<published>2003-05-14T01:43:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=20177#p20177</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=20177#p20177"/>
		<title type="html"><![CDATA[TCL Poker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=20177#p20177"><![CDATA[
I haven't heard of one.<br><br>To check for who has the highest hand, you simply need to keep track of who is playing and who has what cards. The easiest way is to store the information in one or more global variables. You should have a "players" variable that is a list of players. Then perhaps a "hands" array, which has an entry for each player. The entry would be the list of cards the player has.<br><br>To calculate who has the highest hand, you have to program in the rules of poker. Check each hand for pairs, 3 of a kind, 4 of a kind. If you're using jokers/wildcards it will be harder -- calculate the highest group of non-wild cards, or the highest face card value, and add the number of wilds to it.<br><br>Next check for straights. That's pretty easy.. sort the cards from low to high, then check for how many gaps there are. If the length of gaps is greater than the number of wilds, it's not a straight.<br><br>Check for a straight flush.<br><br>Store the highest valued card of each hand, so that if there's a tie you can determine a winner.<br><br>I don't know all the rules but I'm guessing you do. Most rules are pretty straightforward to program into a computer, since computers follow rules very well.<br><br>My advice is to create this scoring function first. Let each card be represented by a letter and a number, like C1 = ace of clubs, C2 = two of clubs, H3 = three of hearts. Then make a simple dcc or public bind to report a score when you say !score C3 C4 C5 C6 C7<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8">stdragon</a> — Wed May 14, 2003 1:43 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[FreakyComputer]]></name></author>
		<updated>2003-05-13T15:40:39-04:00</updated>

		<published>2003-05-13T15:40:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=20166#p20166</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=20166#p20166"/>
		<title type="html"><![CDATA[TCL Poker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=20166#p20166"><![CDATA[
Hiya,<br><br>I was wondering if there is an eggdrop Poker script somewhere. If would be something in the likes of...<br><br>Everyone joins in and the bot gives everyone their cards (as a notice ofcourse) and then the person can exchange the cards, eg. <strong class="text-strong">!change a c e</strong> would exchange his first, third and fifth card. Then the person with the highest hand wins the betted hand<br><br>I think this is called 5 Card Stud, not 100% of the variation's name<br><br>Is there some kind of this out there? Or should I try code for myself. My problem is, I dont know how to check for who has the highest hand.<br><br>So, it will be multiplayer <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>Thanks,<br>FC<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=1240">FreakyComputer</a> — Tue May 13, 2003 3:40 pm</p><hr />
]]></content>
	</entry>
	</feed>
