-rw-r--r-- | noncore/games/sfcave/sfcave.h | 42 |
1 files changed, 28 insertions, 14 deletions
diff --git a/noncore/games/sfcave/sfcave.h b/noncore/games/sfcave/sfcave.h index 18eeef9..b19d147 100644 --- a/noncore/games/sfcave/sfcave.h +++ b/noncore/games/sfcave/sfcave.h @@ -10,11 +10,6 @@ #define MAPSIZE 52 -#define BLOCKSIZE 5 +#define BLOCKSIZE 6 #define TRAILSIZE 30 -#define STATE_BOSS 0 -#define STATE_RUNNING 1 -#define STATE_CRASHED 2 -#define STATE_NEWGAME 3 - -class Main : public QMainWindow +class SFCave : public QMainWindow { @@ -29,2 +24,3 @@ public: int blockHeight; + int gapHeight; int state; @@ -34,2 +30,16 @@ public: + int gateDistance; + int nextGate; + int lastGateBottomY; + + static QString menuOptions[2][5]; + int currentMenuNr; + int nrMenuOptions[2]; + int currentMenuOption[2]; + + static QString dificultyOption[3]; + static QString gameTypes[3]; + int currentGameType; + int currentGameDifficulty; + QPixmap *offscreen; @@ -38,9 +48,9 @@ public: int score; - int highestScore; + int highestScore[3]; - int mapTop[52]; - int mapBottom[52]; - QRect blocks[5]; + int mapTop[MAPSIZE]; + int mapBottom[MAPSIZE]; + QRect blocks[BLOCKSIZE]; QRect user; - QPoint trail[30]; + QPoint trail[TRAILSIZE]; @@ -57,4 +67,4 @@ public: - Main( int speed = 3, QWidget *p = 0, char *name = 0 ); - ~Main(); + SFCave( int speed = 3, QWidget *p = 0, char *name = 0 ); + ~SFCave(); void start(); @@ -65,2 +75,3 @@ public: void addBlock(); + void addGate(); void setPoint( int point ); @@ -70,2 +81,5 @@ public: + void displayMenu(); + void dealWithMenuSelection(); + void keyPressEvent( QKeyEvent *e ); |