Cleaning up shutdown
This commit is contained in:
@@ -72,6 +72,7 @@ public:
|
||||
// Entity signature does not match system signature - erase from set
|
||||
else
|
||||
{
|
||||
system->DestroyComponents(entity_id);
|
||||
system->Entities.erase(entity_id);
|
||||
system->EntitiesToCreate.erase(entity_id);
|
||||
}
|
||||
@@ -82,6 +83,7 @@ public:
|
||||
for (auto const& pair : m_systems)
|
||||
{
|
||||
auto const& system = pair.second;
|
||||
system->DestroyComponents(entity_id);
|
||||
system->Entities.erase(entity_id);
|
||||
system->EntitiesToCreate.erase(entity_id);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user