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.
Character/Character.h@4:b16b6078a432, 2020-05-18 (annotated)
- Committer:
- Albutt
- Date:
- Mon May 18 15:42:26 2020 +0000
- Revision:
- 4:b16b6078a432
- Parent:
- 2:c25ec0da7636
- Child:
- 6:546eba371942
Bullets w/o despawn
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Albutt | 2:c25ec0da7636 | 1 | #include "mbed.h" |
Albutt | 2:c25ec0da7636 | 2 | #include "N5110.h" |
Albutt | 2:c25ec0da7636 | 3 | #include "Gamepad.h" |
Albutt | 2:c25ec0da7636 | 4 | |
Albutt | 2:c25ec0da7636 | 5 | |
Albutt | 2:c25ec0da7636 | 6 | class Character |
Albutt | 2:c25ec0da7636 | 7 | { |
Albutt | 2:c25ec0da7636 | 8 | public: |
Albutt | 2:c25ec0da7636 | 9 | |
Albutt | 2:c25ec0da7636 | 10 | Character(); |
Albutt | 2:c25ec0da7636 | 11 | ~Character(); |
Albutt | 2:c25ec0da7636 | 12 | void init(int x,int y); |
Albutt | 2:c25ec0da7636 | 13 | void draw(N5110 &lcd); |
Albutt | 2:c25ec0da7636 | 14 | void update(Direction d,float mag); |
Albutt | 2:c25ec0da7636 | 15 | void level_up(); |
Albutt | 2:c25ec0da7636 | 16 | int get_level(); |
Albutt | 4:b16b6078a432 | 17 | int get_direction(); |
Albutt | 4:b16b6078a432 | 18 | int get_x(); |
Albutt | 4:b16b6078a432 | 19 | int get_y(); |
Albutt | 2:c25ec0da7636 | 20 | |
Albutt | 2:c25ec0da7636 | 21 | private: |
Albutt | 2:c25ec0da7636 | 22 | |
Albutt | 2:c25ec0da7636 | 23 | int _x; |
Albutt | 2:c25ec0da7636 | 24 | int _y; |
Albutt | 2:c25ec0da7636 | 25 | int _speed; |
Albutt | 2:c25ec0da7636 | 26 | int _level; |
Albutt | 2:c25ec0da7636 | 27 | int _dir; |
Albutt | 2:c25ec0da7636 | 28 | }; |