MCPcopy Create free account
hub / github.com/carbonengine/trinity / Register

Method Register

trinity/Eve/EveEntity.cpp:59–78  ·  view source on GitHub ↗

Registers the entity to an component registry. If the entity has been registered with another registry, then we first unregister the entity

Source from the content-addressed store, hash-verified

57/// Registers the entity to an component registry.
58/// If the entity has been registered with another registry, then we first unregister the entity
59void EveEntity::Register( EveComponentRegistry* registry )
60{
61 if( m_registry == registry )
62 {
63 return;
64 }
65
66 if( m_registry != nullptr )
67 {
68 this->UnRegister( m_registry );
69 }
70
71 if( registry == nullptr )
72 {
73 return;
74 }
75
76 registry->Register( this );
77 this->RegisterComponents();
78}
79
80
81/// Unregisters the entity, but only if it is registered with the registry, else we just ignore this call

Callers 15

Tr2Sprite2dSceneMethod · 0.45
Tr2InteriorSceneMethod · 0.45
InitializeMethod · 0.45
OnListModifiedMethod · 0.45
RegisterComponentsMethod · 0.45
InitializeMethod · 0.45
OnListModifiedMethod · 0.45
SetElementMethod · 0.45
RegisterComponentsMethod · 0.45
SetSourceObjectMethod · 0.45
SetDestObjectMethod · 0.45

Calls 2

UnRegisterMethod · 0.95
RegisterComponentsMethod · 0.45

Tested by

no test coverage detected