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: Ball/Ball.h
- Revision:
- 86:01f33d94e496
- Parent:
- 76:52410264a72d
- Child:
- 91:c01a736fb0d9
--- a/Ball/Ball.h Mon May 06 18:41:24 2019 +0000 +++ b/Ball/Ball.h Mon May 06 19:04:42 2019 +0000 @@ -6,11 +6,15 @@ #include "Gamepad.h" #include "Paddle.h" -/** Ball Class -@author Dr Craig A. Evans, University of Leeds -@brief Controls the ball in the Pong game -@date Febraury 2017 +#define BALL_SIZE 2 +#define BALL_SPEED 2 + +/* Ball Class +@author James Heavey, University of Leeds +@brief Controls the ball in the Breakout game +@date May 2019 */ + class Ball { @@ -20,6 +24,7 @@ void init(int size,int speed,int x); void draw(N5110 &lcd); void update(); + /// accessors and mutators void set_velocity(Vector2D v); Vector2D get_velocity();