summaryrefslogtreecommitdiffstats
path: root/MatchBloxEngine/MatchBloxEngine/C_MatchBloxEngine.h
diff options
context:
space:
mode:
Diffstat (limited to 'MatchBloxEngine/MatchBloxEngine/C_MatchBloxEngine.h')
-rw-r--r--MatchBloxEngine/MatchBloxEngine/C_MatchBloxEngine.h50
1 files changed, 40 insertions, 10 deletions
diff --git a/MatchBloxEngine/MatchBloxEngine/C_MatchBloxEngine.h b/MatchBloxEngine/MatchBloxEngine/C_MatchBloxEngine.h
index f733bcc..b7afa76 100644
--- a/MatchBloxEngine/MatchBloxEngine/C_MatchBloxEngine.h
+++ b/MatchBloxEngine/MatchBloxEngine/C_MatchBloxEngine.h
@@ -8,6 +8,8 @@ class C_3DObject;
class C_Block;
class C_Hand;
class C_Log;
+class C_Environment;
+class C_Box;
typedef enum GameResult
{
@@ -23,33 +25,61 @@ enum EngineState
ES_GET_READY, //game initialised, waiting for start signal from player
ES_PLAYING_GRAB_BLOCK, //no block in hand -> grab floating block
ES_PLAYING_PUT_BLOCK, //block in hand -> put block in box
- ES_PAUSED,
- ES_FINISHED
+ ES_PAUSED, //pause...
+ ES_FINISHED //finished -> show score and goto init
};
+enum BlockType
+{
+ BT_SQUARE = 0,
+ BT_CIRCLE = 1,
+ BT_TRIANGLE = 2,
+ BT_CROSS = 3
+};
+
+enum BoxSize
+{
+ BS_SMALL = 0,
+ BS_MED = 1,
+ BS_LARGE = 2
+};
+
+
class C_MatchBloxEngine
{
- C_MatchBloxEngine(char *f_strModelPath, char *f_strLogFile);
+public:
+ C_MatchBloxEngine(const char *f_strModelPath,
+ const char *f_strLogFile);
~C_MatchBloxEngine();
-public:
GameResult GameStep(msgQueue &f_Queue);
- void Draw(unsigned int f_uiElapsedTime);
+ void Render(unsigned int f_uiElapsedTime);
- bool NewGame(int f_iUserID, int f_iGameId);
+ bool NewGame(int f_iUserID, int f_iGameId, BoxSize f_BS);
bool StartGame();
bool Pause();
bool Resume();
bool Abort();
private:
+ C_Environment *m_pEnvMap;
C_Block *m_pBlock[4];
C_Hand *m_pHand;
- C_3DObject *m_pHole[4],
- *m_pBox;
+ C_3DObject *m_pTiles[5];
+ C_Box *m_pBox[3];
C_Log *m_pLog;
- EngineState m_State;
+ GLuint m_uiWood1Tex,
+ m_uiWood2Tex,
+ m_uiWood3Tex;
+
+ EngineState m_State, m_SavedState;
+ BoxSize m_CurrentBox;
+
+ bool LoadModels(const char* f_strModelDir);
+ void DeleteModels();
+ void LoadTexture(const char* f_BmpName, GLuint &f_uiTexHandle);
};
-#endif //C_MATCHBLOXENGINE_HEADER_FILE \ No newline at end of file
+#endif //C_MATCHBLOXENGINE_HEADER_FILE
+