aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Handlers/LootHandler.cpp
diff options
context:
space:
mode:
authorkandera <kanderacutie@hotmail.com>2012-03-14 09:59:45 -0700
committerkandera <kanderacutie@hotmail.com>2012-03-14 09:59:45 -0700
commitfedb27b601553ef7837ff3d15980493f827fb38f (patch)
treef4e0cab1ba6890bfa7c75fe763859667e4fa03fc /src/server/game/Handlers/LootHandler.cpp
parent69c3612cfe50777e6895ec8a8f57e370a5c99c3e (diff)
parent20cd4c71ee6336610daab304959909b2f6397287 (diff)
Merge pull request #5714 from thomas33/master
more cleanup in files
Diffstat (limited to 'src/server/game/Handlers/LootHandler.cpp')
-rwxr-xr-xsrc/server/game/Handlers/LootHandler.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/server/game/Handlers/LootHandler.cpp b/src/server/game/Handlers/LootHandler.cpp
index 8e4b41a9be4..b4d6db5e80c 100755
--- a/src/server/game/Handlers/LootHandler.cpp
+++ b/src/server/game/Handlers/LootHandler.cpp
@@ -55,15 +55,15 @@ void WorldSession::HandleAutostoreLootItemOpcode(WorldPacket & recv_data)
}
else if (IS_ITEM_GUID(lguid))
{
- Item* pItem = player->GetItemByGuid(lguid);
+ Item* item = player->GetItemByGuid(lguid);
- if (!pItem)
+ if (!item)
{
player->SendLootRelease(lguid);
return;
}
- loot = &pItem->loot;
+ loot = &item->loot;
}
else if (IS_CORPSE_GUID(lguid))
{
@@ -357,29 +357,29 @@ void WorldSession::DoLootRelease(uint64 lguid)
}
else if (IS_ITEM_GUID(lguid))
{
- Item* pItem = player->GetItemByGuid(lguid);
- if (!pItem)
+ Item* item = player->GetItemByGuid(lguid);
+ if (!item)
return;
- ItemTemplate const* proto = pItem->GetTemplate();
+ ItemTemplate const* proto = item->GetTemplate();
// destroy only 5 items from stack in case prospecting and milling
if (proto->Flags & (ITEM_PROTO_FLAG_PROSPECTABLE | ITEM_PROTO_FLAG_MILLABLE))
{
- pItem->m_lootGenerated = false;
- pItem->loot.clear();
+ item->m_lootGenerated = false;
+ item->loot.clear();
- uint32 count = pItem->GetCount();
+ uint32 count = item->GetCount();
// >=5 checked in spell code, but will work for cheating cases also with removing from another stacks.
if (count > 5)
count = 5;
- player->DestroyItemCount(pItem, count, true);
+ player->DestroyItemCount(item, count, true);
}
else
// FIXME: item must not be deleted in case not fully looted state. But this pre-request implement loot saving in DB at item save. Or cheating possible.
- player->DestroyItem(pItem->GetBagSlot(), pItem->GetSlot(), true);
+ player->DestroyItem(item->GetBagSlot(), item->GetSlot(), true);
return; // item can be looted only single player
}
else