Sdk: Add automatic system update
Former-commit-id: ce129cc945e7373ac5b9f48960894712d66b097a
This commit is contained in:
@@ -130,6 +130,15 @@ namespace Ndk
|
||||
RemoveSystem(index);
|
||||
}
|
||||
|
||||
inline void World::Update(float elapsedTime)
|
||||
{
|
||||
Update(); //< Update entities
|
||||
|
||||
// And then update systems
|
||||
for (auto& systemPtr : m_systems)
|
||||
systemPtr->Update(elapsedTime);
|
||||
}
|
||||
|
||||
inline void World::Invalidate()
|
||||
{
|
||||
m_dirtyEntities.Resize(m_entities.size(), false);
|
||||
|
||||
Reference in New Issue
Block a user