Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Author: reeshack <richard.galis@gmail.com> 2011-02-18 18:51:21
- Committer: reeshack <richard.galis@gmail.com> 2011-02-18 18:51:21
- Parent: 78ee00e6d43a51b7c4b20cedd2ed7d2de3c7b6c8 (booooooooooooordel)
- Child: 280d562037f1d517efbe2ad63a167c903217eb50 ([pr1075] Do not split damage if pet is controlled)
- Branches: master, remotes/origin/master, remotes/origin/mmap_new
- Follows: 333a
- Precedes:
- [pr1074] Blood Gorged - remove/add aura at 75% of HP
- Signed-off-by: reeshack <richard.galis@gmail.com>
- ------------------------------ src/game/Unit.cpp ------------------------------
- index 6257831..693afa6 100644
- @@ -12168,6 +12168,35 @@ int32 Unit::ModifyHealth(int32 dVal)
- SetHealth(maxHealth);
- gain = maxHealth - curHealth;
- }
- + // Blood Gorged - remove/add aura at 75% of HP
- + if (GetTypeId() == TYPEID_PLAYER && (Player*)this->getClass() == CLASS_DEATH_KNIGHT)
- + {
- + SpellEntry const* bloodGorgedInfo = NULL;
- + if ((Player*)this->HasSpell(61154))
- + bloodGorgedInfo = sSpellStore.LookupEntry(61154);
- + else if ((Player*)this->HasSpell(61155))
- + bloodGorgedInfo = sSpellStore.LookupEntry(61155);
- + else if ((Player*)this->HasSpell(61156))
- + bloodGorgedInfo = sSpellStore.LookupEntry(61156);
- + else if ((Player*)this->HasSpell(61157))
- + bloodGorgedInfo = sSpellStore.LookupEntry(61157);
- + else if ((Player*)this->HasSpell(61158))
- + bloodGorgedInfo = sSpellStore.LookupEntry(61158);
- +
- + if (bloodGorgedInfo)
- + {
- + if (GetHealthPercent() >= 75.0f)
- + {
- + if (!HasAura(bloodGorgedInfo->EffectTriggerSpell[EFFECT_INDEX_0]))
- + CastSpell(this,bloodGorgedInfo->EffectTriggerSpell[EFFECT_INDEX_0],true);
- + }
- + else
- + {
- + if (HasAura(bloodGorgedInfo->EffectTriggerSpell[EFFECT_INDEX_0]))
- + RemoveAurasDueToSpell(bloodGorgedInfo->EffectTriggerSpell[EFFECT_INDEX_0]);
- + }
- + }
- + }
- return gain;
- }
- --------------------------- src/shared/revision_nr.h ---------------------------
- index 2de315b..62e3406 100644
- @@ -1,6 +1,6 @@
- #ifndef __REVISION_NR_H__
- #define __REVISION_NR_H__
- #define REVISION_NR "11062"
- - #define REVISION_VP "pr1073"
- + #define REVISION_VP "pr1074"
- #define REVISION_VP_DATE "10.2.2011"
- #endif // __REVISION_NR_H__
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement