diff options
author | treeston <treeston.mmoc@gmail.com> | 2015-09-09 18:47:50 +0200 |
---|---|---|
committer | treeston <treeston.mmoc@gmail.com> | 2015-09-09 18:47:50 +0200 |
commit | 946fdbc06b46ee3a357ebfff1128d9d9b38d83d0 (patch) | |
tree | 93c0fa4e1e565273af1ec125f8963650dde16cdf | |
parent | 6cdfe9dc095bd19ea495c22cb41cd82f1212b6cd (diff) |
Allow player-created temporary summons (quest "helper" NPCs summoned by item etc.) to contribute to the 50% player damage requirement.
Fixes quests such as "Valduran the Stormborn" (12984) or "The Air Stands Still" (13125) which previously required the player to out-damage the "helper" NPC to get credit.
-rw-r--r-- | src/server/game/Entities/Unit/Unit.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 0978adc1814..f6632dac4aa 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -721,7 +721,7 @@ uint32 Unit::DealDamage(Unit* victim, uint32 damage, CleanDamage const* cleanDam if (!victim->ToCreature()->hasLootRecipient()) victim->ToCreature()->SetLootRecipient(this); - if (IsControlledByPlayer()) + if (IsControlledByPlayer() || (ToTempSummon() && ToTempSummon()->GetSummoner() && ToTempSummon()->GetSummoner()->GetTypeId() == TYPEID_PLAYER)) victim->ToCreature()->LowerPlayerDamageReq(health < damage ? health : damage); } |