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.
Game/Game.h@11:db27d3838514, 2019-05-06 (annotated)
- Committer:
- joshdavy
- Date:
- Mon May 06 14:43:01 2019 +0000
- Revision:
- 11:db27d3838514
- Parent:
- 9:96969b1c6bde
- Child:
- 12:5549a299d41e
test
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
joshdavy | 11:db27d3838514 | 1 | #ifndef GAME_H |
joshdavy | 1:37802772843e | 2 | #define GAME_H |
joshdavy | 1:37802772843e | 3 | |
joshdavy | 1:37802772843e | 4 | /*Game Class*/ |
joshdavy | 1:37802772843e | 5 | #include "mbed.h" |
joshdavy | 1:37802772843e | 6 | #include "N5110.h" |
joshdavy | 1:37802772843e | 7 | #include "Gamepad.h" |
joshdavy | 1:37802772843e | 8 | #include "Sprite.h" |
joshdavy | 3:b34685dbdb8d | 9 | #include "Player.h" |
joshdavy | 6:2ca1516ec1e2 | 10 | #include "Level.h" |
joshdavy | 11:db27d3838514 | 11 | |
joshdavy | 1:37802772843e | 12 | |
joshdavy | 2:b62e8be35a5d | 13 | |
joshdavy | 2:b62e8be35a5d | 14 | |
joshdavy | 1:37802772843e | 15 | class Game { |
joshdavy | 1:37802772843e | 16 | |
joshdavy | 1:37802772843e | 17 | public: |
joshdavy | 1:37802772843e | 18 | Game(); |
joshdavy | 1:37802772843e | 19 | ~Game(); |
joshdavy | 7:68e06dda79f7 | 20 | void init(); |
joshdavy | 1:37802772843e | 21 | void update(Gamepad &pad); |
joshdavy | 11:db27d3838514 | 22 | void draw(N5110 &lcd); |
joshdavy | 9:96969b1c6bde | 23 | bool game_won(); |
joshdavy | 1:37802772843e | 24 | |
joshdavy | 1:37802772843e | 25 | private: |
joshdavy | 11:db27d3838514 | 26 | void load_level(int level_number); |
joshdavy | 11:db27d3838514 | 27 | |
joshdavy | 3:b34685dbdb8d | 28 | Player _player; |
joshdavy | 6:2ca1516ec1e2 | 29 | Level _level; |
joshdavy | 9:96969b1c6bde | 30 | int _current_level; |
joshdavy | 9:96969b1c6bde | 31 | bool _game_won; |
joshdavy | 1:37802772843e | 32 | }; |
joshdavy | 1:37802772843e | 33 | #endif |