![]() |
Meteor2D
dev internal
Meteor is a lightweight 2D game engine.
|
A scene holds a collection of spatial entity for a specific level. More...
#include <scene.h>
Public Member Functions | |
MScene () | |
Constructor. | |
void | startScene () |
Invoked when scene loads. | |
void | update (float deltaTime) |
Invoked once per frame. | |
void | onClose () |
Invoked during scene unload. | |
void | addToRoot (MSpatialEntity *entity) |
Adds a SpatialEntity to the scene root. | |
size_t | getRootSize () |
Returns size of root. | |
std::vector< MSpatialEntity * > * | getRootEntities () |
Return a list of root entities. | |
bool | tryParse (pugi::xml_document *doc) |
Tries to parse and load a scene state. | |
bool | isClosing () |
template<typename T > | |
T * | find (std::string name) |
Finds a Spatial Entity within this scene. | |
![]() | |
virtual bool | equals (MEntity *other) |
Checks equality between two entities. | |
std::string | getName () |
void | setName (std::string name) |
Sets name of entity. | |
virtual std::string | toString () |
Get this object as a string. | |
Static Public Attributes | |
static const std::string | VALID_SCENE_FILE_XML_TAG |
Friends | |
class | Spatial |
Additional Inherited Members | |
![]() | |
std::string | name |
A scene holds a collection of spatial entity for a specific level.
meteor::MScene::MScene | ( | ) |
Constructor.
deltaTime |
|
inline |