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: GameObject/GameObject.h
- Revision:
- 2:8c5c47b2372d
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/GameObject/GameObject.h Wed Apr 19 00:44:21 2017 +0000
@@ -0,0 +1,30 @@
+#ifndef GAMEOBJECT_H
+#define GAMEOBJECT_H
+
+#include "mbed.h"
+#include "N5110.h"
+#include "Gamepad.h"
+
+class GameObject
+{
+
+public:
+
+ GameObject();
+ ~GameObject();
+
+ int type; // 0 - Platform, 1 - Spike
+ 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
+