zhenye yang
/
el17zy
Yang Zhenye 201199680
Ball/Ball.h
- Committer:
- yangzhenye
- Date:
- 2020-05-15
- Revision:
- 9:a5a82b3d1102
- Parent:
- 5:fcad75e9b9e1
File content as of revision 9:a5a82b3d1102:
#ifndef BALL_H #define BALL_H #include "mbed.h" #include "N5110.h" #include "Gamepad.h" class Ball { public: // Constructor and destructor. /** * @brief Constructor @details Non user specified. */ Ball(); /** * @brief Destructor @details Non user specified. */ ~Ball(); void init(int size,int speed); void draw(N5110 &lcd); void update(); void set_velocity(Vector2D v); Vector2D get_velocity(); Vector2D get_pos(); void set_pos(Vector2D p); private: Vector2D _velocity; int _size; int _x; int _y; }; #endif