8#ifndef GALAXY_SCENE_SCENEMANAGER_HPP_
9#define GALAXY_SCENE_SCENEMANAGER_HPP_
49 void set(const
std::
string& scene);
56 void push(const
std::
string& scene);
Scene saving/loading, creation, changing and loading.
void save_app(const std::string &file)
Save all active scenes and sub data within those scenes.
std::shared_ptr< Scene > top() noexcept
Get top scene.
SceneManager() noexcept
Constructor.
void pop()
Remove scene on top of stack.
void set(const std::string &scene)
Clears all from stack and sets as active.
core::Registry m_registry
Entity data.
std::shared_ptr< Scene > create(const std::string &scene)
Create scene in engine.
void clear()
Deletes all scene data.
void deserialize(const nlohmann::json &json) override
Deserializes from object.
void update()
Handle events and update logic.
void render()
Handle rendering.
nlohmann::json serialize() override
Serializes object.
void pop_all()
Pop all scenes.
std::vector< std::shared_ptr< Scene > > m_stack
Active scenes.
void load_app(const std::string &appdata_file)
Load app data file into scene manager.
bool empty() const
Are there any scenes.
const Map & map() const
Get all scenes.
void push(const std::string &scene)
Push a scene onto the top of stack.
Represents a scene in a game. Like the menu, game, etc. Does not share resources.