summaryrefslogtreecommitdiff
path: root/noncore/games/oyatzee/oyatzee.h
Side-by-side diff
Diffstat (limited to 'noncore/games/oyatzee/oyatzee.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/games/oyatzee/oyatzee.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/noncore/games/oyatzee/oyatzee.h b/noncore/games/oyatzee/oyatzee.h
index 01ab36d..65a18fc 100644
--- a/noncore/games/oyatzee/oyatzee.h
+++ b/noncore/games/oyatzee/oyatzee.h
@@ -5,48 +5,67 @@
#include <qlabel.h>
#include <qlist.h>
#include <stdlib.h> // rand() function
#include <qdatetime.h> // seed for rand()
class Dice;
class Game;
class Scoreboard;
class DiceWidget;
typedef QList<Dice> dicesList;
+typedef QValueList<int> QValueListInt;
class OYatzee : public QMainWindow {
Q_OBJECT
public:
OYatzee( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
~OYatzee();
Game *g;
DiceWidget *dw;
Scoreboard *sb;
+ QValueListInt posibilities;
void setPlayerNumber( const int num );
void setRoundsNumber( const int num );
+
+ enum {
+ Ones=1,
+ Twos = 2,
+ Threes = 3,
+ Fours = 4,
+ Fives = 5,
+ Sixes = 6,
+ ThreeOfAKind = 7, //12444
+ FourOfAKind = 8, //14444
+ FullHouse = 9, //22555
+ SStraight = 10, //13456
+ LStraight = 11, //12345
+ Yatzee = 12, //55555
+ Chance = 13};
public slots:
void slotStartGame();
void slotRollDices();
private:
int numOfPlayers;
int numOfRounds;
void detectPosibilities();
+ void displayPossibilites();
+
};
class Dice : public QFrame
{
Q_OBJECT
public:
Dice( QWidget* parent = 0, const char* name = 0 );
int Value;
bool isSelected;
int hasValue();