From: Loic Blot Date: Thu, 12 Mar 2015 09:32:16 +0000 (+0100) Subject: Don't handle PlayerPos packet coming from client if player is dead X-Git-Tag: 0.4.13~500 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=3067d782169a79ab3b13e8ba3d445b60d0d477c5;p=oweals%2Fminetest.git Don't handle PlayerPos packet coming from client if player is dead --- diff --git a/src/network/packethandlers/server.cpp b/src/network/packethandlers/server.cpp index a11e8dc2f..d24e8df5b 100644 --- a/src/network/packethandlers/server.cpp +++ b/src/network/packethandlers/server.cpp @@ -555,6 +555,11 @@ void Server::handleCommand_PlayerPos(NetworkPacket* pkt) return; } + // If player is dead we don't care of this packet + if (player->hp == 0) { + return; + } + PlayerSAO *playersao = player->getPlayerSAO(); if (playersao == NULL) { errorstream << "Server::ProcessData(): Cancelling: "