Kern Fowler / Mbed 2 deprecated Donkey_Kong_Game

Dependencies:   mbed

Revision:
32:dca62ba807de
Parent:
31:06713cdbba37
--- a/lib/GameEngine/GameEngine.h	Thu May 09 01:40:45 2019 +0000
+++ b/lib/GameEngine/GameEngine.h	Thu May 09 01:52:56 2019 +0000
@@ -8,6 +8,7 @@
 #include "Barrel.h"
 #include "Banana.h"
 #include "HighScores.h"
+#include "Options.h"
 
 /** GameEngine Class
 *@brief This class is running and contrling the main game functions.
@@ -38,9 +39,10 @@
 *@param barrel The Barrel class is used.
 *@param banana The Banana class is used.
 *@param dky The Donkey class is used.
+*@param opt The Options class is used.
 *@details Runs the main functions of the game in correct order.
 *@code
-void GameEngine::gameengine_run(Gamepad &pad, N5110 &lcd, Barrel &barrel, Banana &banana, Donkey &dky) {
+void GameEngine::gameengine_run(Gamepad &pad, N5110 &lcd, Barrel &barrel, Banana &banana, Donkey &dky, Options &opt) {
     wait_ms(250);
     // Sets key variables back to default value when game first ran.
     barrel_x = 0; 
@@ -56,7 +58,7 @@
         lcd.clear();
         dky.donkeykong_movement(pad, lcd); // Calls Donkey Kong model section of game.
         barrel.barrel_drop(pad, lcd, dky); // Calls Barrel model section of game.
-        banana.banana_drop(pad, lcd, barrel, dky); // Calls Banana model section of game.
+        banana.banana_drop(pad, lcd, barrel, dky, opt); // Calls Banana model section of game.
         //printf("state %d", running);
         lcd.refresh(); // Reloads screen on every cycle, controlled by fps. Default set to 24.
         wait_ms(1.0f/24);
@@ -64,7 +66,7 @@
 }
 @endcode
 */
-void gameengine_run(Gamepad &pad, N5110 &lcd, Barrel &barrel, Banana &banana, Donkey &dky);
+void gameengine_run(Gamepad &pad, N5110 &lcd, Barrel &barrel, Banana &banana, Donkey &dky, Options &opt);
 /** 
 *@brief Shows game over screen.
 *@param pad The Gamepad class is used.