mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 13:37:00 +00:00
[10669] Fixed mana amount for overheal case for talent 31785 and ranks.
Also thanks to Wojta for patch code improvements. Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
97ff7e6006
commit
ee1b18cd20
2 changed files with 9 additions and 3 deletions
|
|
@ -1873,7 +1873,13 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
||||||
if (this == pVictim)
|
if (this == pVictim)
|
||||||
return SPELL_AURA_PROC_FAILED;
|
return SPELL_AURA_PROC_FAILED;
|
||||||
|
|
||||||
// heal amount
|
// dont count overhealing
|
||||||
|
uint32 diff = GetMaxHealth()-GetHealth();
|
||||||
|
if (!diff)
|
||||||
|
return SPELL_AURA_PROC_FAILED;
|
||||||
|
if (damage > diff)
|
||||||
|
basepoints[0] = triggerAmount*diff/100;
|
||||||
|
else
|
||||||
basepoints[0] = triggerAmount*damage/100;
|
basepoints[0] = triggerAmount*damage/100;
|
||||||
target = this;
|
target = this;
|
||||||
triggered_spell_id = 31786;
|
triggered_spell_id = 31786;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "10668"
|
#define REVISION_NR "10669"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue