From e441c5c48c4aa66adb5e81884d49009020fe65f9 Mon Sep 17 00:00:00 2001 From: VladimirMangos Date: Tue, 21 Oct 2008 21:57:11 +0400 Subject: [PATCH] Prevent cheating with player loot. --- src/game/WorldSession.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/game/WorldSession.cpp b/src/game/WorldSession.cpp index 64136ddec..60c060567 100644 --- a/src/game/WorldSession.cpp +++ b/src/game/WorldSession.cpp @@ -243,6 +243,9 @@ void WorldSession::LogoutPlayer(bool Save) if (_player) { + if (uint64 lguid = GetPlayer()->GetLootGUID()) + DoLootRelease(lguid); + ///- If the player just died before logging out, make him appear as a ghost //FIXME: logout must be delayed in case lost connection with client in time of combat if (_player->GetDeathTimer())