(World) GetEntity now returns a const reference
Former-commit-id: 179139a21c639bbb2c96058095a82f3be76de5c1
This commit is contained in:
parent
3694857d30
commit
03ef0f9f50
|
|
@ -29,7 +29,7 @@ namespace Ndk
|
|||
|
||||
void Clear();
|
||||
|
||||
EntityHandle GetEntity(Entity::Id id);
|
||||
const EntityHandle& GetEntity(Entity::Id id);
|
||||
|
||||
void KillEntity(const EntityHandle& entity);
|
||||
void KillEntities(const EntityList& list);
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ namespace Ndk
|
|||
m_killedEntities.UnboundedSet(entity->GetId(), true);
|
||||
}
|
||||
|
||||
EntityHandle World::GetEntity(Entity::Id id)
|
||||
const EntityHandle& World::GetEntity(Entity::Id id)
|
||||
{
|
||||
if (IsEntityIdValid(id))
|
||||
return m_aliveEntities[m_entities[id].aliveIndex];
|
||||
|
|
|
|||
Loading…
Reference in New Issue