I can't delete entities inside my systems. When I call entities.delete(entity) it returns Ok(()) but the entity is never being removed. I know that is not being deleted because it's being iterated again in my systems and also when I call entities.is_alive(entity) it always returns true.
Meta
Rust version: 1.47.0
Specs version / commit: 1.16.1
Operating system: Windows 10
This other issue (https://github.com/amethyst/specs/issues/656) helped me to discover what was the problem, I actually have to call world.maintain() on every game tick so the entities can be removed.
Description
I can't delete entities inside my systems. When I call
entities.delete(entity)
it returnsOk(())
but the entity is never being removed. I know that is not being deleted because it's being iterated again in my systems and also when I callentities.is_alive(entity)
it always returns true.Meta
Rust version: 1.47.0 Specs version / commit: 1.16.1 Operating system: Windows 10
Reproduction
Expected behavior
The entity should be deleted from the world.