Arturs Kozlovskis / Mbed 2 deprecated ELEC2645_Project_el18ak

Dependencies:   mbed

Menu/Menu.h

Committer:
thestudent
Date:
2020-05-12
Revision:
21:32429d8e90ff
Parent:
19:913d123554ee
Child:
22:f1811602a817

File content as of revision 21:32429d8e90ff:

#ifndef MENU_H
#define MENU_H
#include "N5110.h"
#include "Gamepad.h"
#include "Objects.h"

/**Menu class
*@brief Makes menu and game screens 
*@author Arturs Kozlovskis
*@date April,2020
*/

class Menu
{
public:
    //functions
    
    /**Constructor
    *@param LCD' object
    *@param Gamepad's object
    */
    Menu(N5110 &lcd,Gamepad &pad);
    /**Make the inital screen
    */
    void first_screen();
    /**Make the menu screen*/
    void menu_screen();
    /**Get game speed
    *@return the current game speed
    */
    string get_game_speed();
    /**Meke the pause screen
    *@return chosen option
    */
    int pause_screen();
    /**Make the game over screen
    *@param the players score
    *@return the chosen option
    */
    int game_over_screen(int score);
    
private:
    //classes
    N5110 _lcd;
    Gamepad _pad;
    //variables
    int _arrow_pos;//holds the menu screen arrow position 
    int _arrow_pos_settings; //holds the setting screen arrow position
    string _game_speed; //holds the game speed
    char print_speed[6]; // holds the game speed in char
};

#endif