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.
Menu/Menu.h@12:d3eef5ea3f43, 2018-05-07 (annotated)
- Committer:
- Andrew_M
- Date:
- Mon May 07 18:06:50 2018 +0000
- Revision:
- 12:d3eef5ea3f43
- Parent:
- 10:279d3775d52c
- Child:
- 14:a57a40ff9430
Functional level select system with 3 different levels, sprite added to main menu for decoration. Minor reorganising within classes was needed, mainly game engine
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| Andrew_M | 8:9d01fd4a63ad | 1 | #include "mbed.h" |
| Andrew_M | 8:9d01fd4a63ad | 2 | #include "N5110.h" |
| Andrew_M | 8:9d01fd4a63ad | 3 | #include "Gamepad.h" |
| Andrew_M | 8:9d01fd4a63ad | 4 | |
| Andrew_M | 9:fe86ddbf7799 | 5 | class Menu |
| Andrew_M | 8:9d01fd4a63ad | 6 | { |
| Andrew_M | 8:9d01fd4a63ad | 7 | public: |
| Andrew_M | 8:9d01fd4a63ad | 8 | |
| Andrew_M | 8:9d01fd4a63ad | 9 | Menu(); |
| Andrew_M | 8:9d01fd4a63ad | 10 | ~Menu(); |
| Andrew_M | 8:9d01fd4a63ad | 11 | void init(); |
| Andrew_M | 9:fe86ddbf7799 | 12 | void read_input(Gamepad &pad); |
| Andrew_M | 9:fe86ddbf7799 | 13 | void update(); |
| Andrew_M | 9:fe86ddbf7799 | 14 | void draw(N5110 &lcd); |
| Andrew_M | 9:fe86ddbf7799 | 15 | bool started(); |
| Andrew_M | 10:279d3775d52c | 16 | int getDif(); |
| Andrew_M | 12:d3eef5ea3f43 | 17 | int getLvl(); |
| Andrew_M | 8:9d01fd4a63ad | 18 | |
| Andrew_M | 8:9d01fd4a63ad | 19 | |
| Andrew_M | 8:9d01fd4a63ad | 20 | private: |
| Andrew_M | 10:279d3775d52c | 21 | |
| Andrew_M | 10:279d3775d52c | 22 | char _d; |
| Andrew_M | 10:279d3775d52c | 23 | bool _start; |
| Andrew_M | 10:279d3775d52c | 24 | int _mainSelection; |
| Andrew_M | 10:279d3775d52c | 25 | int _difSelection; |
| Andrew_M | 10:279d3775d52c | 26 | int _lvlSelection; |
| Andrew_M | 10:279d3775d52c | 27 | bool _buttonPressed; |
| Andrew_M | 10:279d3775d52c | 28 | string _menuScreen; |
| Andrew_M | 10:279d3775d52c | 29 | int _difficulty; |
| Andrew_M | 10:279d3775d52c | 30 | int _level; |
| Andrew_M | 10:279d3775d52c | 31 | |
| Andrew_M | 10:279d3775d52c | 32 | |
| Andrew_M | 8:9d01fd4a63ad | 33 | }; |