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
Menu Class Reference
#include <Menu.h>
Public Member Functions | |
| Menu () | |
| Constructor. | |
| ~Menu () | |
| Destructor. | |
| int | input (int select, Gamepad &pad) |
| initial all the parameter for the snake and food. | |
| void | menus (N5110 &lcd, Gamepad &pad) |
| Main menu for settings and start game. | |
| int | difficulty (N5110 &lcd, Gamepad &pad) |
| select difiiculty. | |
Detailed Description
Menu Class.
Class for settings and start game
- Date:
- 8th May 2019
Definition at line 14 of file Menu.h.
Constructor & Destructor Documentation
Member Function Documentation
select difiiculty.
- Parameters:
-
N5110 *lcd
pointer to the N5110 object in main, address of this pointer is saved to make availability to the entire class, without passing address to each function.
- Parameters:
-
Gamepad *pad
pointer to the gamepad object in main, address of this pointer is saved to make availability to the entire class, without passing address to each function.
- Returns:
- fps
is the frame per second, with higher fps means higher difficulty.
| int input | ( | int | select, |
| Gamepad & | pad | ||
| ) |
initial all the parameter for the snake and food.
- Parameters:
-
select is used to switch the menu. Gamepad *pad
pointer to the gamepad object in main, address of this pointer is saved to make availability to the entire class, without passing address to each function.
Main menu for settings and start game.
- Parameters:
-
N5110 *lcd
pointer to the N5110 object in main, address of this pointer is saved to make availability to the entire class, without passing address to each function.
- Parameters:
-
Gamepad *pad
pointer to the gamepad object in main, address of this pointer is saved to make availability to the entire class, without passing address to each function.
Generated on Tue Jul 12 2022 22:27:32 by
1.7.2