AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
spell_pal_immunities Class Reference
Inheritance diagram for spell_pal_immunities:
SpellScript _SpellScript

Private Member Functions

 PrepareSpellScript (spell_pal_immunities)
 
bool Validate (SpellInfo const *) override
 
SpellCastResult CheckCast ()
 
void TriggerDebuffs ()
 
void Register () override
 

Additional Inherited Members

- Public Member Functions inherited from SpellScript
bool _Validate (SpellInfo const *entry) override
 
bool _Load (Spell *spell)
 
void _InitHit ()
 
bool _IsEffectPrevented (SpellEffIndex effIndex)
 
bool _IsDefaultEffectPrevented (SpellEffIndex effIndex)
 
void _PrepareScriptCall (SpellScriptHookType hookType)
 
void _FinishScriptCall ()
 
bool IsInCheckCastHook () const
 
bool IsInTargetHook () const
 
bool IsInHitPhase () const
 
bool IsInEffectHook () const
 
UnitGetCaster ()
 
UnitGetOriginalCaster ()
 
SpellInfo const * GetSpellInfo ()
 
SpellValue const * GetSpellValue ()
 
WorldLocation const * GetExplTargetDest ()
 
void SetExplTargetDest (WorldLocation &loc)
 
WorldObjectGetExplTargetWorldObject ()
 
UnitGetExplTargetUnit ()
 
GameObjectGetExplTargetGObj ()
 
ItemGetExplTargetItem ()
 
UnitGetHitUnit ()
 
CreatureGetHitCreature ()
 
PlayerGetHitPlayer ()
 
ItemGetHitItem ()
 
GameObjectGetHitGObj ()
 
WorldLocationGetHitDest ()
 
int32 GetHitDamage ()
 
void SetHitDamage (int32 damage)
 
void PreventHitDamage ()
 
int32 GetHitHeal ()
 
void SetHitHeal (int32 heal)
 
void PreventHitHeal ()
 
SpellGetSpell ()
 
AuraGetHitAura ()
 
void PreventHitAura ()
 
void PreventHitEffect (SpellEffIndex effIndex)
 
void PreventHitDefaultEffect (SpellEffIndex effIndex)
 
int32 GetEffectValue () const
 
void SetEffectValue (int32 value)
 
ItemGetCastItem ()
 
void CreateItem (uint32 effIndex, uint32 itemId)
 
SpellInfo const * GetTriggeringSpell ()
 
void FinishCast (SpellCastResult result)
 
void Cancel ()
 
void SetCustomCastResultMessage (SpellCustomErrors result)
 
- Public Member Functions inherited from _SpellScript
 _SpellScript ()
 
virtual ~_SpellScript ()
 
virtual void _Register ()
 
virtual void _Unload ()
 
virtual void _Init (std::string const *scriptname, uint32 spellId)
 
std::string const * _GetScriptName () const
 
virtual bool Load ()
 
virtual void Unload ()
 
- Static Public Member Functions inherited from _SpellScript
static bool ValidateSpellInfo (std::initializer_list< uint32 > spellIds)
 
template<class T >
static bool ValidateSpellInfo (T const &spellIds)
 
- Public Attributes inherited from SpellScript
HookList< CastHandlerBeforeCast
 
HookList< CastHandlerOnCast
 
HookList< CastHandlerAfterCast
 
HookList< CheckCastHandlerOnCheckCast
 
HookList< EffectHandlerOnEffectLaunch
 
HookList< EffectHandlerOnEffectLaunchTarget
 
HookList< EffectHandlerOnEffectHit
 
HookList< EffectHandlerOnEffectHitTarget
 
HookList< BeforeHitHandlerBeforeHit
 
HookList< HitHandlerOnHit
 
HookList< HitHandlerAfterHit
 
HookList< ObjectAreaTargetSelectHandlerOnObjectAreaTargetSelect
 
HookList< ObjectTargetSelectHandlerOnObjectTargetSelect
 
HookList< DestinationTargetSelectHandlerOnDestinationTargetSelect
 
- Protected Attributes inherited from _SpellScript
uint8 m_currentScriptState
 
std::string const * m_scriptName
 
uint32 m_scriptSpellId
 

Detailed Description

Member Function Documentation

◆ CheckCast()

SpellCastResult spell_pal_immunities::CheckCast ( )
inlineprivate
2054 {
2055 Unit* caster = GetCaster();
2056
2057 // for HoP
2058 Unit* target = GetExplTargetUnit();
2059 if (!target)
2060 target = caster;
2061
2062 // "Cannot be used within $61987d. of using Avenging Wrath."
2065
2066 return SPELL_CAST_OK;
2067 }
@ SPELL_FAILED_TARGET_AURASTATE
Definition SharedDefines.h:1048
@ SPELL_CAST_OK
Definition SharedDefines.h:1126
Unit * GetExplTargetUnit()
Definition SpellScript.cpp:433
Unit * GetCaster()
Definition SpellScript.cpp:401
Definition Unit.h:664
bool HasAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint8 reqEffMask=0) const
Definition Unit.cpp:5982
@ SPELL_PALADIN_AVENGING_WRATH_MARKER
Definition spell_paladin.cpp:54
@ SPELL_PALADIN_FORBEARANCE
Definition spell_paladin.cpp:53

References SpellScript::GetCaster(), SpellScript::GetExplTargetUnit(), Unit::HasAura(), SPELL_CAST_OK, SPELL_FAILED_TARGET_AURASTATE, SPELL_PALADIN_AVENGING_WRATH_MARKER, and SPELL_PALADIN_FORBEARANCE.

Referenced by Register().

◆ PrepareSpellScript()

spell_pal_immunities::PrepareSpellScript ( spell_pal_immunities  )
private

◆ Register()

void spell_pal_immunities::Register ( )
inlineoverrideprivatevirtual

Implements _SpellScript.

2081 {
2084 }
#define SpellCheckCastFn(F)
Definition SpellScript.h:329
#define SpellHitFn(F)
Definition SpellScript.h:349
HookList< CheckCastHandler > OnCheckCast
Definition SpellScript.h:328
HookList< HitHandler > AfterHit
Definition SpellScript.h:347
void TriggerDebuffs()
Definition spell_paladin.cpp:2069
SpellCastResult CheckCast()
Definition spell_paladin.cpp:2053

References SpellScript::AfterHit, CheckCast(), SpellScript::OnCheckCast, SpellCheckCastFn, SpellHitFn, and TriggerDebuffs().

◆ TriggerDebuffs()

void spell_pal_immunities::TriggerDebuffs ( )
inlineprivate
2070 {
2071 if (Unit* target = GetHitUnit())
2072 {
2073 // Blizz seems to just apply aura without bothering to cast
2077 }
2078 }
Unit * GetHitUnit()
Definition SpellScript.cpp:448
Aura * AddAura(uint32 spellId, Unit *target)
Definition Unit.cpp:15088
@ SPELL_PALADIN_IMMUNE_SHIELD_MARKER
Definition spell_paladin.cpp:55

References Unit::AddAura(), SpellScript::GetCaster(), SpellScript::GetHitUnit(), SPELL_PALADIN_AVENGING_WRATH_MARKER, SPELL_PALADIN_FORBEARANCE, and SPELL_PALADIN_IMMUNE_SHIELD_MARKER.

Referenced by Register().

◆ Validate()

bool spell_pal_immunities::Validate ( SpellInfo const *  )
inlineoverrideprivatevirtual

Reimplemented from _SpellScript.

2044 {
2045 return ValidateSpellInfo(
2046 {
2050 });
2051 }
static bool ValidateSpellInfo(std::initializer_list< uint32 > spellIds)
Definition SpellScript.h:125

References SPELL_PALADIN_AVENGING_WRATH_MARKER, SPELL_PALADIN_FORBEARANCE, SPELL_PALADIN_IMMUNE_SHIELD_MARKER, and _SpellScript::ValidateSpellInfo().


The documentation for this class was generated from the following file: