ELEC2645 (2017/18) / Mbed 2 deprecated fy15raf

Dependencies:   mbed

Revision:
6:7b733b2a6cf6
Parent:
3:489437d4ebd7
Child:
7:06c86ec1f19d
diff -r b230e79d36d6 -r 7b733b2a6cf6 Rocket/Rocket.cpp
--- a/Rocket/Rocket.cpp	Thu Apr 19 17:46:28 2018 +0000
+++ b/Rocket/Rocket.cpp	Fri Apr 20 21:03:05 2018 +0000
@@ -61,4 +61,20 @@
     if (_x > WIDTH - 7) {
         _x = WIDTH - 7;
     }
+}
+
+Vector2D Rocket::get_pos() {
+    Vector2D p = {_x,_y};
+    return p;    
+}
+
+
+void Rocket::add_score()
+{
+    _score++;
+}
+
+int Rocket::get_score()
+{
+    return _score;
 }
\ No newline at end of file