Peoplemon  0.1.0
Peoplemon 3 game source documentation
SaveGame.hpp
Go to the documentation of this file.
1 #ifndef GAME_STATES_SAVEGAME_HPP
2 #define GAME_STATES_SAVEGAME_HPP
3 
4 #include <BLIB/Graphics/Sprite.hpp>
5 #include <Game/States/State.hpp>
6 
7 namespace game
8 {
9 namespace state
10 {
16 class SaveGame : public State {
17 public:
24  static bl::engine::State::Ptr create(core::system::Systems& systems);
25 
29  virtual ~SaveGame() = default;
30 
34  virtual const char* name() const override;
35 
41  virtual void activate(bl::engine::Engine& engine) override;
42 
48  virtual void deactivate(bl::engine::Engine& engine) override;
49 
56  virtual void update(bl::engine::Engine& engine, float dt, float) override;
57 
58 private:
59  bl::rc::res::TextureRef bgndTxtr;
60  bl::gfx::Sprite background;
61 
63  void onFinish();
64 };
65 
66 } // namespace state
67 } // namespace game
68 
69 #endif
Parent namespace for all functionality unique to the game.
Owns all primary systems and a reference to the engine.
Definition: Systems.hpp:47
Basic engine state for when the game is saved.
Definition: SaveGame.hpp:16
virtual ~SaveGame()=default
Destroy the Save Game state.
virtual void activate(bl::engine::Engine &engine) override
Activates the state.
Definition: SaveGame.cpp:25
virtual const char * name() const override
Returns "SaveGame".
Definition: SaveGame.cpp:23
virtual void update(bl::engine::Engine &engine, float dt, float) override
Updates the state and menus and whatnot.
Definition: SaveGame.cpp:40
static bl::engine::State::Ptr create(core::system::Systems &systems)
Creates the save game state.
Definition: SaveGame.cpp:11
virtual void deactivate(bl::engine::Engine &engine) override
Deactivates the state.
Definition: SaveGame.cpp:36
Parent to all game states. Provides some commonly required data like core game systems.
Definition: State.hpp:29
core::system::Systems & systems
Definition: State.hpp:66