49 lines
733 B
C++
49 lines
733 B
C++
|
#ifndef PAUSE_STATE_HPP_INCLUDED
|
||
|
#define PAUSE_STATE_HPP_INCLUDED
|
||
|
|
||
|
|
||
|
#include <iostream>
|
||
|
#include <SDL/SDL.h>
|
||
|
|
||
|
#include "game.hpp"
|
||
|
#include "gamestate.hpp"
|
||
|
#include "menuitem.hpp"
|
||
|
#include "menu.hpp"
|
||
|
|
||
|
|
||
|
class PauseState : public GameState
|
||
|
{
|
||
|
public:
|
||
|
void Init();
|
||
|
void Clean();
|
||
|
|
||
|
void Pause();
|
||
|
void Resume();
|
||
|
|
||
|
void HandleEvents ( game * Game );
|
||
|
void Update ( game * Game );
|
||
|
void Draw ( game * Game );
|
||
|
|
||
|
// Implement Singleton Pattern
|
||
|
static PauseState * Instance()
|
||
|
{
|
||
|
return &m_PauseState;
|
||
|
}
|
||
|
|
||
|
|
||
|
static void resume ( game * Game );
|
||
|
static void go_to_menu ( game * Game );
|
||
|
static void quit ( game * Game );
|
||
|
|
||
|
protected:
|
||
|
PauseState() {}
|
||
|
|
||
|
private:
|
||
|
static PauseState m_PauseState;
|
||
|
|
||
|
Menu * menu;
|
||
|
};
|
||
|
|
||
|
|
||
|
#endif
|