Godzil hace 3 años
padre
commit
de6d748a6a
Se han modificado 1 ficheros con 4 adiciones y 1 borrados
  1. 4 1
      source/ECS.cpp

+ 4 - 1
source/ECS.cpp

@@ -149,7 +149,10 @@ void Registry::update()
 
         for(auto pool: this->componentPools)
         {
-            pool->removeEntityFromPool(entity.getId());
+            if (pool != nullptr)
+            {
+                pool->removeEntityFromPool(entity.getId());
+            }
         }
 
         this->freeIds.push_back(entity.getId());