Ahmed Adamjee
/
SnakeVSBlock
Snake vs Block Game to be run upon K64F.
Diff: GameEngine/WinLoose/WinLoose.h
- Revision:
- 83:329da564799a
- Parent:
- 51:387249f9b333
- Child:
- 93:7f9c31ed5cab
diff -r c51ae8a501d1 -r 329da564799a GameEngine/WinLoose/WinLoose.h --- a/GameEngine/WinLoose/WinLoose.h Mon May 06 10:49:50 2019 +0000 +++ b/GameEngine/WinLoose/WinLoose.h Mon May 06 14:28:35 2019 +0000 @@ -12,27 +12,38 @@ WinLoose(); ~WinLoose(); + /** Initialise WinLoose + * + * This function initialises the WinLoose Class. + */ + void init(N5110 *lcd, Gamepad *pad); + /** Level Complete * * This function prepares the game for the next level and initialises WinLoose and obtains required class addresses to use in other functions. */ - int LevelComplete(N5110 &lcd, Gamepad &pad, int level); + int LevelComplete(int level); /** Display Level * * Displays the level on screen. */ - void displayLevel(N5110 &lcd, int level); + void displayLevel(int level); /** Game Over * * This function does the required tasks to implement a loosing screen. */ - void GameOver(N5110 &lcd, Gamepad &pad); + void GameOver(); private: char bufferlevel[14]; //this helps me print the level on screen. + //Pointer to the game pad object pad. + Gamepad *_pad; + //Pointer to the N5110 object lcd. + N5110 *_lcd; + };