From 57a9410e22356f361e53c3ad80085ba62b862203 Mon Sep 17 00:00:00 2001 From: tartalo Date: Sat, 24 Oct 2009 20:09:02 +0200 Subject: [PATCH] Fix KillCredit effect when is casted by players. Thanks Azuritus --HG-- branch : trunk --- src/game/Player.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/game/Player.cpp b/src/game/Player.cpp index 607a1a7626..979db05fd6 100644 --- a/src/game/Player.cpp +++ b/src/game/Player.cpp @@ -20291,9 +20291,9 @@ bool Player::RewardPlayerAndGroupAtKill(Unit* pVictim) void Player::RewardPlayerAndGroupAtEvent(uint32 creature_id, WorldObject* pRewardSource) { - if (!pRewardSource || pRewardSource->GetTypeId() != TYPEID_UNIT) + if (!pRewardSource) return; - uint64 creature_guid = pRewardSource->GetGUID(); + uint64 creature_guid = (pRewardSource->GetTypeId() == TYPEID_UNIT) ? pRewardSource->GetGUID() : uint64(0); // prepare data for near group iteration if(Group *pGroup = GetGroup())