4
Diff: Ball1.h
- Revision:
- 5:381cd0ea08aa
diff -r d3f87c8e4027 -r 381cd0ea08aa Ball1.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Ball1.h Thu May 04 06:38:59 2017 +0000 @@ -0,0 +1,33 @@ +#ifndef BALL1_H +#define BALL1_H + +#include "mbed.h" +#include "N5110.h" +#include "Gamepad.h" +#include "Paddle.h" + + +class Ball1 +{ + +public: + Ball1(); + ~Ball1(); + void init(int size,int speed); + void draw(N5110 &lcd); + void update(Direction d,float mag); + /// accessors and mutators + void set_velocity(Vector2D v); + Vector2D get_velocity(); + Vector2D get_pos(); + void set_pos(Vector2D p); + void set_size(int size); + +private: + + Vector2D _velocity; + int _size; + int _x; + int _y; +}; +#endif \ No newline at end of file