Library that draws a basket on a Nokia N5110 LCD display and allows it to be moved left/right on the display using buttons or a joystick.
Dependents: Game_Controller_Project
Basket.h
- Committer:
- Nathanj94
- Date:
- 2017-04-22
- Revision:
- 9:05fd30d491f1
- Parent:
- 8:48c5adc809e1
- Child:
- 10:2e441532206e
File content as of revision 9:05fd30d491f1:
#ifndef BASKET_H #define BASKET_H #include "mbed.h" #include "N5110.h" #include "Gamepad.h" class Basket { public: Basket(); ~Basket(); //INITILISATION FUNCTION// void init(int y, int width); //UPDATE FUNCTIONS// void move_stick(Direction d, float mag); void move_LR(Gamepad &pad); //SCORE FUNCTIONS// void add_score_1(); void add_score_2(); void add_score_5(); void add_score_10(); int get_score(); //DISPLAY FUNCTIONS// void draw(N5110 &lcd); int get_x(); int get_y(); private: int y_ref; int x_ref; int basket_width; int stick_speed; int score; }; #endif