From 8973492619443785cccc5a794ba47c437a51db34 Mon Sep 17 00:00:00 2001 From: ubpa Date: Tue, 18 May 2021 21:00:31 +0800 Subject: [PATCH] Update EntityMngr.cpp --- src/core/EntityMngr.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/EntityMngr.cpp b/src/core/EntityMngr.cpp index 5550b7d..08f3530 100644 --- a/src/core/EntityMngr.cpp +++ b/src/core/EntityMngr.cpp @@ -79,7 +79,7 @@ CmptAccessPtr EntityMngr::GetComponent(Entity e, AccessTypeID type) const { } bool EntityMngr::Exist(Entity e) const noexcept { - return e.index < entityTable.size() && e.version == entityTable[e.index].version; + return e.index < entityTable.size() && e.version == entityTable[e.index].version && entityTable[e.index].archetype; } std::size_t EntityMngr::RequestEntityFreeEntry() {