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.
Paddle/Paddle.h
- Committer:
- jamesheavey
- Date:
- 2019-04-21
- Revision:
- 9:f6f0f39538c7
- Parent:
- 0:7d4d2023ed9c
- Child:
- 16:1761dfe801af
File content as of revision 9:f6f0f39538c7:
#ifndef PADDLE_H
#define PADDLE_H
#include "mbed.h"
#include "N5110.h"
#include "Gamepad.h"
class Paddle
{
public:
Paddle();
~Paddle();
void init(int x,int height,int width);
void draw(N5110 &lcd);
void update(Direction d,float mag);
void add_score();
void lose_life();
int get_score();
Vector2D get_pos();
int get_lives();
private:
int _height;
int _width;
int _x;
int _y;
int _speed;
int _score;
int _lives;
};
#endif