Ahmed Adamjee
/
SnakeVSBlock
Snake vs Block Game to be run upon K64F.
Diff: MenuClasses/StartScreen/StartScreen.h
- Revision:
- 91:ca8cff78f2fe
- Parent:
- 88:1e2e70a484e7
- Child:
- 92:693a6ae0ff8e
diff -r 741120c09784 -r ca8cff78f2fe MenuClasses/StartScreen/StartScreen.h --- a/MenuClasses/StartScreen/StartScreen.h Wed May 08 21:01:20 2019 +0000 +++ b/MenuClasses/StartScreen/StartScreen.h Wed May 08 21:29:06 2019 +0000 @@ -23,73 +23,107 @@ /** Destructor */ ~StartScreen(); - /** Initialises all parameters of the Game Interface, assigns some default values and calls other init() functions. - * @param 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. - * @param 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. + /** + * @brief Initialises all parameters of the Game Interface, assigns some default values and calls other init() functions. + * @param N5110 *lcd @details 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. + * @param Gamepad *pad @details 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. */ void init(N5110 *lcd, Gamepad *pad); - /**This function initialises the class objects that are the diffrent parts of the game (Eg: SnakeFood Class).*/ + /** + * @brief This function initialises the class objects that are the diffrent parts of the game (Eg: SnakeFood Class). + */ void object_initialisations(); - /** Draws the Title Sprite onto the screen and plays theme song.*/ + /** + * @brief Draws the Title Sprite onto the screen and plays theme song. + */ void titleScreen(); - /** Instructs the user about how to progress after the title screen has been displayed.*/ + /** + * @brief Instructs the user about how to progress after the title screen has been displayed. + */ void instruct(); - /** Shows who the author of the game is before starting the game. This function's functionality can be hidden using settings.*/ + /** + * @brief Shows who the author of the game is before starting the game. This function's functionality can be hidden using settings. + */ void credits(); - /** Reads stored statistics using the Stats class in the sd card and saves it for displaying in the menu. - *@param The SDFileSystem library + /** + * @brief Reads stored statistics using the Stats class in the sd card and saves it for displaying in the menu. + *@param SDFileSystem &sd @details The SDFileSystem library. @code _stats.read(sd); @endcode */ void read_stats(SDFileSystem &sd); - /** Checks BACK if button pressed in a loop, can be used to exit it and also remember if true/false and used for various conditions. - * @return True if the BACK pressed, else False. + /** + * @brief Checks BACK if button pressed in a loop, can be used to exit it and also remember if true/false and used for various conditions. + * @return _backPressed @detalis True if the BACK pressed, else False. */ bool checkBackPressed(); - /** Checks if START or A buttons are pressed in a loop, can be used to terminate it and also remember if true/false and used for various conditions. - * @return True if the START or A pressed, else False. + /** + * @brief Checks if START or A buttons are pressed in a loop, can be used to terminate it and also remember if true/false and used for various conditions. + * @return _startPressed @details True if the START or A pressed, else False. */ bool checkStartorAPressed(); - /** Waits for the user to select a menu option and calls a related function*/ + /** + * @brief Waits for the user to select a menu option and calls a related function. + */ void menu(); - /** Displays all the Main Menu contents to the player and allows the user to navigate using drawSelectionArrow().*/ + /** + * @brief Displays all the Main Menu contents to the player and allows the user to navigate using drawSelectionArrow(). + */ void mainMenu(); - /** Draws an arrow to aid the selection of main menu options.*/ + /** + * @brief Draws an arrow to aid the selection of main menu options. + */ void drawSelectionArrow(); - /** Calls the next menu item dependent on the input in mainMenu().*/ + /** + * @brief Calls the next menu item dependent on the input in mainMenu(). + */ void nextMenu(); - /** Obtains the user input on the game mode they would like to play on (Joystick or Motion Control).*/ + /** + * @brief Obtains the user input on the game mode they would like to play on (Joystick or Motion Control). + */ void game_mode(); - /** Value of g_mode is changed in this function that allows the choice between joystick/motion control.*/ + /** + * @brief Value of g_mode is changed in this function that allows the choice between joystick/motion control. + */ void selectMode(); - /** Changes the page displayed in the game mode menu*/ + /** + * @brief Changes the page displayed in the game mode menu + */ void scrollModeSelection(); - /** Promts the user to press A to centre position their angle during the game if Motion Control is selected.*/ + /** + * @brief Promts the user to press A to centre position their angle during the game if Motion Control is selected. + */ void motionControlInstructions(); - /** Obtains the user input on the game speed to be used later in the SnakevsBlock class.*/ + /** + * @brief Obtains the user input on the game speed to be used later in the SnakevsBlock class. + */ void game_speed(); - /** Value of fps is changed in this function that will be used as frames per second in my game loop in main.cpp.*/ + /** + * @brief Value of fps is changed in this function that will be used as frames per second in my game loop in main.cpp. + */ void selectSpeed(); - /** Changes the page displayed in the game speed menu*/ + /** + * @brief Changes the page displayed in the game speed menu + */ void scrollSpeedSelection();