[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-games-devel
Subject:    [Kde-games-devel] KPoker and the card images
From:       Inge Wallin <inge () lysator ! liu ! se>
Date:       2004-08-25 21:08:19
Message-ID: Pine.GSO.4.51L2.0408252257360.26893 () sellafield ! lysator ! liu ! se
[Download RAW message or body]

Hi again,

I am now done writing a PokerHand class that handles all aspekts of (guess
what...) a Poker hand.  This will ultimately be used to fix bug 30272, a
misevaluation of several different hands.  However, when i tested it, very
strange things happened.

I traced the problems to the fact that the cards that I thought I had,
were not the ones that got displayed.  Then I looked at the card decks
(image files) in libkdegames and got very surprised by the order in which
they were stored.

Card "1.png" is the Ace of Clubs, "2.png" was the Ace of Spades, and so
on.  Card "52.png" is two of diamonds.  Some questions:

1. Why this order for the suits?  The order of the suits, as far as I
know, clubs, diamonds, spades and hearts in increasing order.

2. Why this order of ranks?  Why have the best cards using the lowest
indices?  Wouldn't the other way around be more intuitive?

3. Is this a standard order that is defined anywhere?  If so, where?

4. Wouldn't some other card classes than just images be a good addition to
libkdegames?  I have written a few for this project that I can brush up
and then let you look at and decide if it is a good idea.

	-Inge


Inge Wallin               | Thus spake the master programmer:               |
                          |      "After three days without programming,     |
inge@lysator.liu.se       |       life becomes meaningless."                |
                          | Geoffrey James: The Tao of Programming.         |
_______________________________________________
kde-games-devel mailing list
kde-games-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-games-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic