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.
Life_Powerup/Life_Powerup.h
- Committer:
- jamesheavey
- Date:
- 2019-05-08
- Revision:
- 114:280903dd7e06
- Child:
- 129:b47c28c7eaaf
File content as of revision 114:280903dd7e06:
#ifndef LIFE_POWERUP_H #define LIFE_POWERUP_H #include "mbed.h" #include "N5110.h" #include "Gamepad.h" #include "Paddle.h" #include "Bitmap.h" /* Life_Powerup Class @author James Heavey, University of Leeds @brief Controls the Life_Powerup in the Breakout game @date May 2019 */ static int powerup_data[] = { 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0 }; class Life_Powerup { public: Life_Powerup(); ~Life_Powerup(); void init(); void draw(N5110 &lcd); void update(); /// accessors and mutators int get_x(); int get_y(); void set_posx(int x); void set_posy(int y); private: int _speed_y; int _x; int _y; }; #endif