WIP Model component not working.

This commit is contained in:
Jocke
2016-01-11 14:34:04 +01:00
parent 6c13916eec
commit b37ffc7449
8 changed files with 204 additions and 67 deletions
+7 -1
View File
@@ -80,7 +80,13 @@ ComponentWrapper World::AttachComponent(EntityID entity, std::string componentTy
return c;
}
bool World::HasComponent(EntityID entity, std::string componentType) const
bool World::HasEntity(EntityID entity)
{
return m_EntityParents.find(entity) != m_EntityParents.end();
}
bool World::HasComponent(EntityID entity, std::string componentType)
{
ComponentPool* pool = m_ComponentPools.at(componentType);
return pool->KnowsEntity(entity);