ELEC2645 (2016/17) / Mbed 2 deprecated 2645_Project_el15as

Dependencies:   mbed

Revision:
4:1f7f32f3e017
Child:
5:158e2951654b
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/GameObject/GameObject.h	Mon Apr 24 22:32:40 2017 +0000
@@ -0,0 +1,33 @@
+#ifndef GAMEOBJECT_H
+#define GAMEOBJECT_H
+
+#include "mbed.h"
+#include "N5110.h"
+#include "Gamepad.h"
+
+
+
+class GameObject
+{
+    #define OBJECTCOUNT 37
+
+public:
+
+    GameObject();
+    ~GameObject();
+
+    int type; // 0 - Platform, 1 - Horizontal Spikes, 2 - Vertical Spikes
+    intVector2D position; // top left corner
+    int width;
+    int height;
+
+    bool containsPoint(int x, int y);
+
+private:
+
+    bool containsX(int _x);
+    bool containsY(int _y);
+
+};
+#endif
+