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.
Diff: Map/Map.h
- Revision:
- 6:39bda45efeed
- Parent:
- 5:12c179da4788
- Child:
- 7:cd3cafda3dd4
diff -r 12c179da4788 -r 39bda45efeed Map/Map.h
--- a/Map/Map.h Tue Mar 26 09:16:35 2019 +0000
+++ b/Map/Map.h Mon Apr 08 09:14:33 2019 +0000
@@ -6,6 +6,7 @@
#include "Gamepad.h"
#include "PlayerControl.h"
#include "Ball.h"
+#include <vector>
/** Map Class
@author Kostadin Chakarov, University of Leeds
@@ -13,20 +14,22 @@
@date March 2019
*/
-struct Centerpoints
-{
- int x;
- int y;
+struct Brick {
+ int x, y, w, h;
};
class Map
{
+private:
+ std::vector<Brick> bricks;
public:
Map();
~Map();
- void setCenterpoints();
+ void initBricks();
void drawMap(N5110 &lcd);
+ void checkCollision(GameObject &obj);
+ void destroyMap(N5110 &lcd, Gamepad &pad, Ball &ball);
private: