From 2ea60156437962d7d29d20606bf5d9189059f76b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Lo=C3=AFc=20Blot?= Date: Sat, 21 Jan 2017 10:41:00 +0100 Subject: [PATCH] Do not force deletion of players when mapblock is full (#5081) This fixes #4067 --- src/serverenvironment.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/serverenvironment.cpp b/src/serverenvironment.cpp index d3b85a430..41cd63684 100644 --- a/src/serverenvironment.cpp +++ b/src/serverenvironment.cpp @@ -2146,6 +2146,12 @@ void ServerEnvironment::deactivateFarObjects(bool force_delete) continue; } + // If it's a forced delete, there are too many objects in mapblock + // Ignore players, they should not be removed on force delete + if (force_delete && obj->getType() == ACTIVEOBJECT_TYPE_PLAYER) { + continue; + } + verbosestream<<"ServerEnvironment::deactivateFarObjects(): " <<"object id="<