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.
Dependencies: mbed
TankL/Tank.h
- Committer:
- el17mcd
- Date:
- 2019-04-14
- Revision:
- 12:9e6d5d0a0c82
- Parent:
- TankL/TankL.h@ 11:4e2eb64031a0
File content as of revision 12:9e6d5d0a0c82:
#ifndef TANK_H #define TANK_H #include "mbed.h" #include "N5110.h" #include "Gamepad.h" class Tank { public: Tank(); ~Tank(); //Accessors int get_position_x(); int get_position_y(); int get_hitbox(int i); int get_health(); //Mutators void set_position(int x, int y); void set_health(int h); void set_speed(int s); void set_angle(float angle); //Other Methods void move_position(int d); void lose_health(); void generate_hitbox(); private: int _position_x; int _position_y; int _move_counter; int _angle; int _speed; int _hitbox[40]; int _health; }; #endif // TANK_H