JianWei Lee
/
project_game
Meteor defense project
GameEngine/GameEngine.h
- Committer:
- jasper0712
- Date:
- 2017-04-24
- Revision:
- 37:45da88e36d1d
- Parent:
- 36:2608622e5018
- Child:
- 38:c66a69c1a6de
File content as of revision 37:45da88e36d1d:
#ifndef GAMEENGINE_H #define GAMEENGINE_H #include "mbed.h" #include "N5110.h" #include "Gamepad.h" #include "Weapon.h" #include "Spawn.h" #include "GUI.h" #define Rows 48 #define Cols 84 class GameEngine { public: GameEngine(); ~GameEngine(); void drawSpawn(N5110 &lcd); void drawLaserPlayer(Gamepad &pad, N5110 &lcd); void checkGameRule(Gamepad &pad, N5110 &lcd); void gameWave(); //not yet started void bombAndShield(Gamepad &pad, N5110 &lcd); void updateArray(); void init(int w); void update(Gamepad &pad, N5110 &lcd); void weapUpgrade(Gamepad &pad, N5110 &lcd); void startingMenu(Gamepad &pad, N5110 &lcd); void numberOfLife_leds(Gamepad &pad); int doneUpgrade_flag; int Array[Cols][Rows]; //main int Array2[Cols][Rows]; // secondary //this char array to differentiate the 4 different kind of spawn - a, b, c and d. char charArray[Cols][Rows]; //used as main array char charArray2[Cols][Rows]; //secondary array private: Weapon weap; Weapon _d1; Weapon _d2; Spawn spa; GUI _gui; int drawit; int ledNumber; int NumberOfLife; int fireInTheHole_flag; }; #endif