47 #ifndef FLATLAND_SERVER_ENTITY_H 48 #define FLATLAND_SERVER_ENTITY_H 50 #include <Box2D/Box2D.h> 51 #include <flatland_server/yaml_reader.h> 52 #include <yaml-cpp/yaml.h> 74 Entity(b2World *physics_world,
const std::string &name);
75 virtual ~
Entity() =
default;
80 const std::string &
GetName()
const;
111 #endif // FLATLAND_SERVER_ENTITY_H EntityType
Defines the type of entity.
Definition: entity.h:64
b2World * GetPhysicsWorld()
Get Box2D physics world.
Definition: entity.cpp:57
virtual void DebugVisualize() const =0
Visualize the entity.
Entity(b2World *physics_world, const std::string &name)
Constructor for the entity.
Definition: entity.cpp:52
b2World * physics_world_
Box2D physics world.
Definition: entity.h:66
const std::string & GetName() const
Definition: entity.cpp:55
virtual EntityType Type() const =0
Get the type of entity, subclasses must override.
virtual void DebugOutput() const =0
Print debug message for the entity.
std::string name_
name of the entity
Definition: entity.h:67