From 0a27273d6414e6d97b622ff59cc38d27d3db8188 Mon Sep 17 00:00:00 2001 From: RicardoCampos Date: Tue, 21 Oct 2014 22:48:42 +0100 Subject: [PATCH] Bugfix: Corpse stays locked when looting fails If looting fails either because of cooldown or there are items on your cursor, the client is sent an end loot packet- the client releases the corpse but no one else can loot. This simply resets BeingLootedBy in this instance. --- zone/corpse.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/zone/corpse.cpp b/zone/corpse.cpp index da9ffab17..7300db608 100644 --- a/zone/corpse.cpp +++ b/zone/corpse.cpp @@ -1069,6 +1069,10 @@ void Corpse::LootItem(Client* client, const EQApplicationPacket* app) if(!loot_cooldown_timer.Check()) { SendEndLootErrorPacket(client); + //unlock corpse for others + if (this->BeingLootedBy = client->GetID()) { + BeingLootedBy = 0xFFFFFFFF; + } return; } @@ -1077,6 +1081,10 @@ void Corpse::LootItem(Client* client, const EQApplicationPacket* app) { client->Message(13, "You may not loot an item while you have an item on your cursor."); SendEndLootErrorPacket(client); + //unlock corpse for others + if (this->BeingLootedBy = client->GetID()) { + BeingLootedBy = 0xFFFFFFFF; + } return; }