aboutsummaryrefslogtreecommitdiff
path: root/src/game/Player.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/Player.cpp')
-rw-r--r--src/game/Player.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/game/Player.cpp b/src/game/Player.cpp
index 7305a2ac3f4..6893ac3a04a 100644
--- a/src/game/Player.cpp
+++ b/src/game/Player.cpp
@@ -16119,12 +16119,12 @@ bool Player::LoadFromDB( uint32 guid, SqlQueryHolder *holder )
return true;
}
-bool Player::isAllowedToLoot(Creature* creature)
+bool Player::isAllowedToLoot(const Creature* creature)
{
- if (creature->isDead() && !creature->IsDamageEnoughForLootingAndReward())
+ if (!creature->isDead() || !creature->IsDamageEnoughForLootingAndReward())
return false;
- Loot* loot = &creature->loot;
+ const Loot* loot = &creature->loot;
if (loot->items.size() == 0)
return false;