Radium Engine
1.5.20
|
#include <Engine/Scene/ItemEntry.hpp>
Public Member Functions | |
ItemEntry ()=default | |
Create an invalid entry. | |
ItemEntry (Entity *ent, Component *comp=nullptr, Ra::Core::Utils::Index ro=Ra::Core::Utils::Index::Invalid()) | |
bool | operator== (const ItemEntry &rhs) const |
Compare two items. | |
bool | isValid () const |
Returns true if the item represents any valid object. | |
bool | isSelectable () const |
Returns true if the item can be selected. | |
bool | isEntityNode () const |
Returns true if the item represents an entity. | |
bool | isComponentNode () const |
Returns true if the item represents a component. | |
bool | isRoNode () const |
Returns true if the item represents a render object. | |
void | checkConsistency () const |
Debug checks. | |
Public Attributes | |
Entity * | m_entity { nullptr } |
The entity represented by the item, or owning the object represented. | |
Component * | m_component { nullptr } |
Ra::Core::Utils::Index | m_roIndex {} |
RO index of the represented object. | |
This represent a handle for an entity, component or render object. There are 4 possible states for this object :
Definition at line 25 of file ItemEntry.hpp.
|
inlineexplicit |
Create an entry. ItemEntry(entity) creates an entity entry. ItemEntry(entity, component) creates a component entry ItemEntry(entity, component, RO) creates a render object entity.
Definition at line 33 of file ItemEntry.hpp.
|
inline |
Debug checks.
Definition at line 95 of file ItemEntry.hpp.
|
inline |
Returns true if the item represents a component.
Definition at line 85 of file ItemEntry.hpp.
|
inline |
Returns true if the item represents an entity.
Definition at line 80 of file ItemEntry.hpp.
|
inline |
Returns true if the item represents a render object.
Definition at line 90 of file ItemEntry.hpp.
bool Ra::Engine::Scene::ItemEntry::isSelectable | ( | ) | const |
Returns true if the item can be selected.
Definition at line 52 of file ItemEntry.cpp.
bool Ra::Engine::Scene::ItemEntry::isValid | ( | ) | const |
Returns true if the item represents any valid object.
Definition at line 42 of file ItemEntry.cpp.
|
inline |
Compare two items.
Definition at line 101 of file ItemEntry.hpp.
Component* Ra::Engine::Scene::ItemEntry::m_component { nullptr } |
Component represented by the item or owning the represented RO. If null, the item represents an entity.
Definition at line 64 of file ItemEntry.hpp.
Entity* Ra::Engine::Scene::ItemEntry::m_entity { nullptr } |
The entity represented by the item, or owning the object represented.
Definition at line 60 of file ItemEntry.hpp.
Ra::Core::Utils::Index Ra::Engine::Scene::ItemEntry::m_roIndex {} |
RO index of the represented object.
Definition at line 67 of file ItemEntry.hpp.