8#ifndef GALAXY_SCENE_SCENE_HPP_
9#define GALAXY_SCENE_SCENE_HPP_
11#include <ankerl/unordered_dense.h>
83 const std::string&
name()
const noexcept;
98 void deserialize(
const nlohmann::json& json)
override;
120 graphics::Camera m_camera;
125 entt::dispatcher m_dispatcher;
140 int m_velocity_iterations;
145 int m_position_iterations;*/
Wrapper around entt::registry to expand functionality.
Allows a class to be serialized.
Represents a scene in a game. Like the menu, game, etc.
void add_system(const std::string &system)
Add a system to operate on entities in this scene.
void load()
When scene is loaded and made active.
Scene()=delete
Constructor.
const std::string & name() const noexcept
Get scene name.
virtual ~Scene()
Destructor.
meta::SystemStack m_systems
List of systems to run.
std::string m_name
Scene name for debug purposes.
nlohmann::json serialize() override
Serializes object.
void update(core::Registry ®istry)
Process events and updates.
void deserialize(const nlohmann::json &json) override
Deserializes from object.
void unload()
When scene is deactivated / unloaded.