Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
Diff: Gameengine/Gameengine.h
- Revision:
- 21:7a7a115d910d
- Parent:
- 20:78bd235f8caa
- Child:
- 23:1ee8686af747
diff -r 78bd235f8caa -r 7a7a115d910d Gameengine/Gameengine.h
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/Gameengine/Gameengine.h Wed Apr 03 01:17:38 2019 +0000
@@ -0,0 +1,36 @@
+#ifndef GAMEERENGINE_H
+#define GAMEERENGINE_H
+
+#include "mbed.h"
+#include "N5110.h"
+#include "Gamepad.h"
+#include "Minerengine.h"
+#include "Level1.h"
+
+class Gameengine
+{
+
+public:
+
+ Gameengine();
+ ~Gameengine();
+ void read_direction(Gamepad &pad);
+ void update(N5110 &lcd, Gamepad &pad);
+ void game_init();
+ void draw(N5110 &lcd, Gamepad &pad);
+ void lose_life(N5110 &lcd);
+ bool game_over();
+ void next_level(N5110 &lcd);
+
+private:
+
+ Minerengine _miner;
+ Direction _d;
+ int _level_select;
+ Level1 _l1;
+ int _lives;
+ Timer t;
+
+};
+
+#endif