JianWei Lee
/
project_game
Meteor defense project
Diff: GameEngine/GameEngine.cpp
- Revision:
- 30:2e2d48cbfec3
- Parent:
- 29:6632dd9c48d8
- Child:
- 31:1c0e47931e84
--- a/GameEngine/GameEngine.cpp Tue Apr 18 11:21:35 2017 +0000 +++ b/GameEngine/GameEngine.cpp Tue Apr 18 21:50:14 2017 +0000 @@ -9,11 +9,11 @@ { } -void GameEngine::init() { +void GameEngine::init(int w) { _d1.droneInit(20, 46, 0, 42); //drone1 is taking left side pixel 0 to 42. _d2.droneInit(62, 46, 42, 84); //drone2 is taking right side pixel 42 to 84; weap.init(); - spa.init(); + spa.init(w); //printf("init completed \n"); } void GameEngine::update(Gamepad &pad, N5110 &lcd) { @@ -57,8 +57,8 @@ } else { drawit -= 0.5; spa.moveSpawnDE(Array, Array2, charArray, charArray2); - spa.moveSpawnB(Array, Array2, charArray, charArray2); - //printf("moving spawn b \n"); + spa.moveSpawnB(Array, Array2, charArray, charArray2); + //printf("moving spawn abcde \n"); } spa.updateSpawn(Array, Array2, charArray, charArray2, lcd); //checkGameRule(lcd);