File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Client/mods/deathmatch/logic/luadefs
Server/mods/deathmatch/logic/luadefs Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -952,7 +952,7 @@ int CLuaElementDefs::GetElementsWithinRange(lua_State* luaVM)
952
952
953
953
for (CClientEntity* entity : result)
954
954
{
955
- if (elementType.empty () || elementType == entity->GetTypeName ())
955
+ if (( elementType.empty () || elementType == entity->GetTypeName ()) && !entity-> IsBeingDeleted ())
956
956
{
957
957
lua_pushnumber (luaVM, ++index);
958
958
lua_pushelement (luaVM, entity);
Original file line number Diff line number Diff line change @@ -1010,7 +1010,7 @@ int CLuaElementDefs::getElementsWithinRange(lua_State* luaVM)
1010
1010
1011
1011
for (CElement* entity : result)
1012
1012
{
1013
- if (elementType.empty () || elementType == entity->GetTypeName ())
1013
+ if (( elementType.empty () || elementType == entity->GetTypeName ()) && !entity-> IsBeingDeleted ())
1014
1014
{
1015
1015
lua_pushnumber (luaVM, ++index);
1016
1016
lua_pushelement (luaVM, entity);
You can’t perform that action at this time.
0 commit comments