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: PeopleEngine/People.h
- Revision:
- 9:62d6559f0d50
- Parent:
- 4:b12a49f0b730
- Child:
- 11:494cc44777fe
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/PeopleEngine/People.h Sat May 09 08:27:07 2020 +0000
@@ -0,0 +1,41 @@
+/** People class
+ @set a basic element of my project
+ @author Zeyu Feng
+ @9 April 2020
+ */
+#ifndef PEOPLE_H
+#define PEOPLE_H
+
+#include "mbed.h"
+#include "Gamepad.h"
+#include "N5110.h"
+
+class People {
+
+public:
+ People(); //Constructor
+
+ ~People(); //Destructor
+
+ void init();
+
+ void draw(N5110 &lcd);
+
+ void update();
+
+ //accessors
+ void set_pos(Vector2D p);
+
+ void set_velocity(Direction d,float mag);
+
+ //mutators
+ Vector2D get_pos();
+
+private:
+ Direction _d;
+ float _mag;
+ int _x;
+ int _y;
+};
+#endif
+
\ No newline at end of file