2010-06-06 01:22:01 +02:00
|
|
|
#ifndef USERINTERFACE
|
|
|
|
#define USERINTERFACE
|
|
|
|
|
|
|
|
namespace Engine {
|
|
|
|
class OverlayBase;
|
|
|
|
}
|
|
|
|
|
|
|
|
#include "OverlayBase.h"
|
|
|
|
#include "Sprite.h"
|
2010-07-15 22:47:17 +02:00
|
|
|
#include <string>
|
2010-06-06 01:22:01 +02:00
|
|
|
|
|
|
|
namespace asteroids {
|
|
|
|
|
|
|
|
class Model;
|
|
|
|
class View;
|
|
|
|
|
|
|
|
class MainMenuOverlay : public Engine::OverlayBase {
|
|
|
|
public:
|
|
|
|
MainMenuOverlay () {
|
|
|
|
};
|
|
|
|
virtual ~MainMenuOverlay() {};
|
|
|
|
|
|
|
|
virtual void Init ();
|
|
|
|
|
|
|
|
virtual bool OnKeyDown (const SDL_keysym &keysym);
|
|
|
|
virtual void Draw ();
|
|
|
|
|
|
|
|
private:
|
|
|
|
Engine::Sprite mShipSprite;
|
|
|
|
};
|
|
|
|
|
|
|
|
class GameRunningOverlay : public Engine::OverlayBase {
|
|
|
|
public:
|
|
|
|
GameRunningOverlay () {
|
|
|
|
};
|
|
|
|
virtual ~GameRunningOverlay() {};
|
|
|
|
|
|
|
|
virtual void Init ();
|
|
|
|
|
|
|
|
virtual bool OnKeyDown (const SDL_keysym &keysym);
|
|
|
|
virtual void Draw ();
|
|
|
|
|
|
|
|
private:
|
|
|
|
Engine::Sprite mShipSprite;
|
|
|
|
};
|
|
|
|
|
|
|
|
class GameOverOverlay : public Engine::OverlayBase {
|
|
|
|
public:
|
|
|
|
GameOverOverlay () {
|
|
|
|
};
|
|
|
|
virtual ~GameOverOverlay() {};
|
|
|
|
|
|
|
|
virtual void Init ();
|
|
|
|
|
|
|
|
virtual bool OnKeyDown (const SDL_keysym &keysym);
|
|
|
|
virtual void Draw ();
|
|
|
|
};
|
|
|
|
|
|
|
|
class LevelCompleteOverlay : public Engine::OverlayBase {
|
|
|
|
public:
|
|
|
|
LevelCompleteOverlay () {
|
|
|
|
};
|
|
|
|
virtual ~LevelCompleteOverlay() {};
|
|
|
|
|
|
|
|
virtual void Init ();
|
|
|
|
|
|
|
|
virtual bool OnKeyDown (const SDL_keysym &keysym);
|
|
|
|
virtual void Draw ();
|
|
|
|
};
|
|
|
|
|
|
|
|
class GamePausedOverlay : public Engine::OverlayBase {
|
|
|
|
public:
|
|
|
|
GamePausedOverlay () {
|
|
|
|
};
|
|
|
|
virtual ~GamePausedOverlay() {};
|
|
|
|
|
|
|
|
virtual void Init ();
|
|
|
|
|
|
|
|
virtual bool OnKeyDown (const SDL_keysym &keysym);
|
|
|
|
virtual void Draw ();
|
|
|
|
};
|
|
|
|
|
|
|
|
class PlayerDiedOverlay : public Engine::OverlayBase {
|
|
|
|
public:
|
|
|
|
PlayerDiedOverlay () {
|
|
|
|
};
|
|
|
|
virtual ~PlayerDiedOverlay() {};
|
|
|
|
|
|
|
|
virtual void Init ();
|
|
|
|
|
|
|
|
virtual bool OnKeyDown (const SDL_keysym &keysym);
|
|
|
|
virtual void Draw ();
|
|
|
|
};
|
|
|
|
|
2010-06-10 23:30:29 +02:00
|
|
|
class HighscoreOverlay : public Engine::OverlayBase {
|
|
|
|
public:
|
|
|
|
HighscoreOverlay () {
|
|
|
|
};
|
|
|
|
virtual ~HighscoreOverlay() {};
|
|
|
|
|
|
|
|
virtual void Init ();
|
|
|
|
|
|
|
|
virtual bool OnKeyDown (const SDL_keysym &keysym);
|
|
|
|
virtual void Draw ();
|
|
|
|
};
|
|
|
|
|
2010-07-15 22:47:17 +02:00
|
|
|
class EnterPlayernameOverlay : public Engine::OverlayBase {
|
|
|
|
public:
|
|
|
|
EnterPlayernameOverlay () {
|
|
|
|
};
|
|
|
|
virtual ~EnterPlayernameOverlay() {};
|
|
|
|
|
|
|
|
virtual void Init ();
|
|
|
|
|
|
|
|
virtual bool OnKeyDown (const SDL_keysym &keysym);
|
|
|
|
virtual void Draw ();
|
|
|
|
|
|
|
|
private:
|
|
|
|
std::string mPlayerNameInput;
|
|
|
|
};
|
|
|
|
|
2010-06-06 01:22:01 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
#endif /* USERINTERFACE */
|
|
|
|
|