summaryrefslogtreecommitdiff
path: root/noncore/games/sfcave/sfcave.h
authorandyq <andyq>2002-12-13 15:03:41 (UTC)
committer andyq <andyq>2002-12-13 15:03:41 (UTC)
commit28a78f938ae995fbc29f76afa84b1bee62178a79 (patch) (side-by-side diff)
tree47fdf14787de5748acafb151a63222b726a42a20 /noncore/games/sfcave/sfcave.h
parent18c7cd23a85562cd23a4161e1006138e602a0be7 (diff)
downloadopie-28a78f938ae995fbc29f76afa84b1bee62178a79.zip
opie-28a78f938ae995fbc29f76afa84b1bee62178a79.tar.gz
opie-28a78f938ae995fbc29f76afa84b1bee62178a79.tar.bz2
Cleanup up some code, replays now know what game they were saved for, moved
the replay stuff into its own menu, and allowed the menus to have3 more items each.
Diffstat (limited to 'noncore/games/sfcave/sfcave.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/games/sfcave/sfcave.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/noncore/games/sfcave/sfcave.h b/noncore/games/sfcave/sfcave.h
index 238a615..65e5ae4 100644
--- a/noncore/games/sfcave/sfcave.h
+++ b/noncore/games/sfcave/sfcave.h
@@ -9,13 +9,14 @@
#include "random.h"
#define MAPSIZE 52
#define BLOCKSIZE 6
#define TRAILSIZE 30
-
+#define NR_MENUS 3
+#define MAX_MENU_OPTIONS 8
class SFCave : public QMainWindow
{
Q_OBJECT
public:
@@ -50,16 +51,16 @@ public:
double maxDownThrust;
int gateDistance;
int nextGate;
int lastGateBottomY;
- static QString menuOptions[2][5];
+ static QString menuOptions[NR_MENUS][MAX_MENU_OPTIONS];
int currentMenuNr;
- static int nrMenuOptions[2];
- static int currentMenuOption[2];
+ static int nrMenuOptions[NR_MENUS];
+ static int currentMenuOption[NR_MENUS];
static QString dificultyOption[3];
static QString gameTypes[3];
int currentGameType;
int currentGameDifficulty;
@@ -104,12 +105,13 @@ public:
void addGate();
void setPoint( int point );
void drawBoss();
void draw();
void handleKeys();
+ void handleMenuKeys( QKeyEvent * e );
void displayMenu();
void dealWithMenuSelection();
void keyPressEvent( QKeyEvent *e );
void keyReleaseEvent( QKeyEvent *e );
void saveScore();