Improved interface
EntityHandle are no longer required to pass Entity as arguments World::CreateEntity() now returns a const EntityHandle& Former-commit-id: 6fc53ce5759a2a508094bdc61b4471f13f0844ec
This commit is contained in:
@@ -45,7 +45,7 @@ namespace Ndk
|
||||
|
||||
void Entity::Kill()
|
||||
{
|
||||
m_world->KillEntity(CreateHandle());
|
||||
m_world->KillEntity(this);
|
||||
}
|
||||
|
||||
bool Entity::IsValid() const
|
||||
@@ -88,7 +88,7 @@ namespace Ndk
|
||||
if (m_world->HasSystem(systemId))
|
||||
{
|
||||
BaseSystem& system = m_world->GetSystem(systemId);
|
||||
system.RemoveEntity(CreateHandle());
|
||||
system.RemoveEntity(this);
|
||||
}
|
||||
}
|
||||
m_systems.clear();
|
||||
|
||||
Reference in New Issue
Block a user