TrinityCore
SpellScript.h File Reference
#include "ObjectGuid.h"
#include "SharedDefines.h"
#include "SpellAuraDefines.h"
#include "Util.h"
#include <stack>
+ Include dependency graph for SpellScript.h:

Go to the source code of this file.

Classes

class  _SpellScript
 
class  _SpellScript::EffectHook
 
class  _SpellScript::EffectNameCheck
 
class  _SpellScript::EffectAuraNameCheck
 
class  SpellScript
 
class  SpellScript::CastHandler
 
class  SpellScript::CheckCastHandler
 
class  SpellScript::EffectHandler
 
class  SpellScript::HitHandler
 
class  SpellScript::BeforeHitHandler
 
class  SpellScript::OnCalcCritChanceHandler
 
class  SpellScript::TargetHook
 
class  SpellScript::ObjectAreaTargetSelectHandler
 
class  SpellScript::ObjectTargetSelectHandler
 
class  SpellScript::DestinationTargetSelectHandler
 
class  SpellScript::OnCalculateResistAbsorbHandler
 
class  AuraScript
 
class  AuraScript::CheckAreaTargetHandler
 
class  AuraScript::AuraDispelHandler
 
class  AuraScript::EffectBase
 
class  AuraScript::EffectPeriodicHandler
 
class  AuraScript::EffectUpdatePeriodicHandler
 
class  AuraScript::EffectCalcAmountHandler
 
class  AuraScript::EffectCalcPeriodicHandler
 
class  AuraScript::EffectCalcSpellModHandler
 
class  AuraScript::EffectCalcCritChanceHandler
 
class  AuraScript::EffectApplyHandler
 
class  AuraScript::EffectAbsorbHandler
 
class  AuraScript::EffectManaShieldHandler
 
class  AuraScript::EffectSplitHandler
 
class  AuraScript::CheckProcHandler
 
class  AuraScript::CheckEffectProcHandler
 
class  AuraScript::AuraProcHandler
 
class  AuraScript::EffectProcHandler
 
class  AuraScript::EnterLeaveCombatHandler
 
class  AuraScript::ScriptStateStore
 

Macros

#define SPELL_EFFECT_ANY   (uint16)-1
 
#define SPELL_AURA_ANY   (uint16)-1
 
#define SPELL_SCRIPT_STATE_END   SPELL_SCRIPT_STATE_UNLOADING + 1
 
#define HOOK_SPELL_HIT_START   SPELL_SCRIPT_HOOK_EFFECT_HIT
 
#define HOOK_SPELL_HIT_END   SPELL_SCRIPT_HOOK_AFTER_HIT + 1
 
#define SPELLSCRIPT_FUNCTION_TYPE_DEFINES(CLASSNAME)
 
#define SPELLSCRIPT_FUNCTION_CAST_DEFINES(CLASSNAME)
 
#define PrepareSpellScript(CLASSNAME)   SPELLSCRIPT_FUNCTION_TYPE_DEFINES(CLASSNAME) SPELLSCRIPT_FUNCTION_CAST_DEFINES(CLASSNAME)
 
#define SpellCastFn(F)   CastHandlerFunction(&F)
 
#define SpellCheckCastFn(F)   CheckCastHandlerFunction(&F)
 
#define SpellOnResistAbsorbCalculateFn(F)   OnCalculateResistAbsorbHandlerFunction(&F)
 
#define SpellEffectFn(F, I, N)   EffectHandlerFunction(&F, I, N)
 
#define BeforeSpellHitFn(F)   BeforeHitHandlerFunction(&F)
 
#define SpellHitFn(F)   HitHandlerFunction(&F)
 
#define SpellOnCalcCritChanceFn(F)   OnCalcCritChanceHandlerFunction(&F)
 
#define SpellObjectAreaTargetSelectFn(F, I, N)   ObjectAreaTargetSelectHandlerFunction(&F, I, N)
 
#define SpellObjectTargetSelectFn(F, I, N)   ObjectTargetSelectHandlerFunction(&F, I, N)
 
#define SpellDestinationTargetSelectFn(F, I, N)   DestinationTargetSelectHandlerFunction(&F, I, N)
 
#define AURASCRIPT_FUNCTION_TYPE_DEFINES(CLASSNAME)
 
#define AURASCRIPT_FUNCTION_CAST_DEFINES(CLASSNAME)
 
#define PrepareAuraScript(CLASSNAME)   AURASCRIPT_FUNCTION_TYPE_DEFINES(CLASSNAME) AURASCRIPT_FUNCTION_CAST_DEFINES(CLASSNAME)
 
#define AuraCheckAreaTargetFn(F)   CheckAreaTargetFunction(&F)
 
#define AuraDispelFn(F)   AuraDispelFunction(&F)
 
#define AuraEffectApplyFn(F, I, N, M)   EffectApplyHandlerFunction(&F, I, N, M)
 
#define AuraEffectRemoveFn(F, I, N, M)   EffectApplyHandlerFunction(&F, I, N, M)
 
#define AuraEffectPeriodicFn(F, I, N)   EffectPeriodicHandlerFunction(&F, I, N)
 
#define AuraEffectUpdatePeriodicFn(F, I, N)   EffectUpdatePeriodicHandlerFunction(&F, I, N)
 
#define AuraEffectCalcAmountFn(F, I, N)   EffectCalcAmountHandlerFunction(&F, I, N)
 
#define AuraEffectCalcPeriodicFn(F, I, N)   EffectCalcPeriodicHandlerFunction(&F, I, N)
 
#define AuraEffectCalcSpellModFn(F, I, N)   EffectCalcSpellModHandlerFunction(&F, I, N)
 
#define AuraEffectCalcCritChanceFn(F, I, N)   EffectCalcCritChanceHandlerFunction(&F, I, N)
 
#define AuraEffectAbsorbFn(F, I)   EffectAbsorbFunction(&F, I)
 
#define AuraEffectAbsorbOverkillFn(F, I)   EffectAbsorbFunction(&F, I, true)
 
#define AuraEffectManaShieldFn(F, I)   EffectManaShieldFunction(&F, I)
 
#define AuraEffectSplitFn(F, I)   EffectSplitFunction(&F, I)
 
#define AuraCheckProcFn(F)   CheckProcHandlerFunction(&F)
 
#define AuraCheckEffectProcFn(F, I, N)   CheckEffectProcHandlerFunction(&F, I, N)
 
#define AuraProcFn(F)   AuraProcHandlerFunction(&F)
 
#define AuraEffectProcFn(F, I, N)   EffectProcHandlerFunction(&F, I, N)
 
#define AuraEnterLeaveCombatFn(F)   EnterLeaveCombatFunction(&F)
 

Enumerations

enum  SpellScriptState { SPELL_SCRIPT_STATE_NONE = 0, SPELL_SCRIPT_STATE_REGISTRATION, SPELL_SCRIPT_STATE_LOADING, SPELL_SCRIPT_STATE_UNLOADING }
 
enum  SpellScriptHookType {
  SPELL_SCRIPT_HOOK_EFFECT_LAUNCH = SPELL_SCRIPT_STATE_END, SPELL_SCRIPT_HOOK_EFFECT_LAUNCH_TARGET, SPELL_SCRIPT_HOOK_EFFECT_HIT, SPELL_SCRIPT_HOOK_EFFECT_HIT_TARGET,
  SPELL_SCRIPT_HOOK_EFFECT_SUCCESSFUL_DISPEL, SPELL_SCRIPT_HOOK_BEFORE_HIT, SPELL_SCRIPT_HOOK_HIT, SPELL_SCRIPT_HOOK_AFTER_HIT,
  SPELL_SCRIPT_HOOK_OBJECT_AREA_TARGET_SELECT, SPELL_SCRIPT_HOOK_OBJECT_TARGET_SELECT, SPELL_SCRIPT_HOOK_DESTINATION_TARGET_SELECT, SPELL_SCRIPT_HOOK_CHECK_CAST,
  SPELL_SCRIPT_HOOK_BEFORE_CAST, SPELL_SCRIPT_HOOK_ON_CAST, SPELL_SCRIPT_HOOK_ON_RESIST_ABSORB_CALCULATION, SPELL_SCRIPT_HOOK_AFTER_CAST,
  SPELL_SCRIPT_HOOK_CALC_CRIT_CHANCE, SPELL_SCRIPT_HOOK_ON_PRECAST
}
 
enum  AuraScriptHookType {
  AURA_SCRIPT_HOOK_EFFECT_APPLY = SPELL_SCRIPT_STATE_END, AURA_SCRIPT_HOOK_EFFECT_AFTER_APPLY, AURA_SCRIPT_HOOK_EFFECT_REMOVE, AURA_SCRIPT_HOOK_EFFECT_AFTER_REMOVE,
  AURA_SCRIPT_HOOK_EFFECT_PERIODIC, AURA_SCRIPT_HOOK_EFFECT_UPDATE_PERIODIC, AURA_SCRIPT_HOOK_EFFECT_CALC_AMOUNT, AURA_SCRIPT_HOOK_EFFECT_CALC_PERIODIC,
  AURA_SCRIPT_HOOK_EFFECT_CALC_SPELLMOD, AURA_SCRIPT_HOOK_EFFECT_CALC_CRIT_CHANCE, AURA_SCRIPT_HOOK_EFFECT_ABSORB, AURA_SCRIPT_HOOK_EFFECT_AFTER_ABSORB,
  AURA_SCRIPT_HOOK_EFFECT_MANASHIELD, AURA_SCRIPT_HOOK_EFFECT_AFTER_MANASHIELD, AURA_SCRIPT_HOOK_EFFECT_SPLIT, AURA_SCRIPT_HOOK_CHECK_AREA_TARGET,
  AURA_SCRIPT_HOOK_DISPEL, AURA_SCRIPT_HOOK_AFTER_DISPEL, AURA_SCRIPT_HOOK_ENTER_LEAVE_COMBAT, AURA_SCRIPT_HOOK_CHECK_PROC,
  AURA_SCRIPT_HOOK_CHECK_EFFECT_PROC, AURA_SCRIPT_HOOK_PREPARE_PROC, AURA_SCRIPT_HOOK_PROC, AURA_SCRIPT_HOOK_EFFECT_PROC,
  AURA_SCRIPT_HOOK_EFFECT_AFTER_PROC, AURA_SCRIPT_HOOK_AFTER_PROC
}
 

Macro Definition Documentation

◆ AuraCheckAreaTargetFn

#define AuraCheckAreaTargetFn (   F)    CheckAreaTargetFunction(&F)

◆ AuraCheckEffectProcFn

#define AuraCheckEffectProcFn (   F,
  I,
 
)    CheckEffectProcHandlerFunction(&F, I, N)

◆ AuraCheckProcFn

#define AuraCheckProcFn (   F)    CheckProcHandlerFunction(&F)

◆ AuraDispelFn

#define AuraDispelFn (   F)    AuraDispelFunction(&F)

◆ AuraEffectAbsorbFn

#define AuraEffectAbsorbFn (   F,
 
)    EffectAbsorbFunction(&F, I)

◆ AuraEffectAbsorbOverkillFn

#define AuraEffectAbsorbOverkillFn (   F,
 
)    EffectAbsorbFunction(&F, I, true)

◆ AuraEffectApplyFn

#define AuraEffectApplyFn (   F,
  I,
  N,
 
)    EffectApplyHandlerFunction(&F, I, N, M)

◆ AuraEffectCalcAmountFn

#define AuraEffectCalcAmountFn (   F,
  I,
 
)    EffectCalcAmountHandlerFunction(&F, I, N)

◆ AuraEffectCalcCritChanceFn

#define AuraEffectCalcCritChanceFn (   F,
  I,
 
)    EffectCalcCritChanceHandlerFunction(&F, I, N)

◆ AuraEffectCalcPeriodicFn

#define AuraEffectCalcPeriodicFn (   F,
  I,
 
)    EffectCalcPeriodicHandlerFunction(&F, I, N)

◆ AuraEffectCalcSpellModFn

#define AuraEffectCalcSpellModFn (   F,
  I,
 
)    EffectCalcSpellModHandlerFunction(&F, I, N)

◆ AuraEffectManaShieldFn

#define AuraEffectManaShieldFn (   F,
 
)    EffectManaShieldFunction(&F, I)

◆ AuraEffectPeriodicFn

#define AuraEffectPeriodicFn (   F,
  I,
 
)    EffectPeriodicHandlerFunction(&F, I, N)

◆ AuraEffectProcFn

#define AuraEffectProcFn (   F,
  I,
 
)    EffectProcHandlerFunction(&F, I, N)

◆ AuraEffectRemoveFn

#define AuraEffectRemoveFn (   F,
  I,
  N,
 
)    EffectApplyHandlerFunction(&F, I, N, M)

◆ AuraEffectSplitFn

#define AuraEffectSplitFn (   F,
 
)    EffectSplitFunction(&F, I)

◆ AuraEffectUpdatePeriodicFn

#define AuraEffectUpdatePeriodicFn (   F,
  I,
 
)    EffectUpdatePeriodicHandlerFunction(&F, I, N)

◆ AuraEnterLeaveCombatFn

#define AuraEnterLeaveCombatFn (   F)    EnterLeaveCombatFunction(&F)

◆ AuraProcFn

#define AuraProcFn (   F)    AuraProcHandlerFunction(&F)

◆ AURASCRIPT_FUNCTION_CAST_DEFINES

#define AURASCRIPT_FUNCTION_CAST_DEFINES (   CLASSNAME)
Value:
class CheckAreaTargetFunction : public AuraScript::CheckAreaTargetHandler { public: explicit CheckAreaTargetFunction(AuraCheckAreaTargetFnType _pHandlerScript) : AuraScript::CheckAreaTargetHandler((AuraScript::AuraCheckAreaTargetFnType)_pHandlerScript) { } }; \
class AuraDispelFunction : public AuraScript::AuraDispelHandler { public: explicit AuraDispelFunction(AuraDispelFnType _pHandlerScript) : AuraScript::AuraDispelHandler((AuraScript::AuraDispelFnType)_pHandlerScript) { } }; \
class EffectPeriodicHandlerFunction : public AuraScript::EffectPeriodicHandler { public: explicit EffectPeriodicHandlerFunction(AuraEffectPeriodicFnType _pEffectHandlerScript, uint8 _effIndex, uint16 _effName) : AuraScript::EffectPeriodicHandler((AuraScript::AuraEffectPeriodicFnType)_pEffectHandlerScript, _effIndex, _effName) { } }; \
class EffectUpdatePeriodicHandlerFunction : public AuraScript::EffectUpdatePeriodicHandler { public: explicit EffectUpdatePeriodicHandlerFunction(AuraEffectUpdatePeriodicFnType _pEffectHandlerScript, uint8 _effIndex, uint16 _effName) : AuraScript::EffectUpdatePeriodicHandler((AuraScript::AuraEffectUpdatePeriodicFnType)_pEffectHandlerScript, _effIndex, _effName) { } }; \
class EffectCalcAmountHandlerFunction : public AuraScript::EffectCalcAmountHandler { public: explicit EffectCalcAmountHandlerFunction(AuraEffectCalcAmountFnType _pEffectHandlerScript, uint8 _effIndex, uint16 _effName) : AuraScript::EffectCalcAmountHandler((AuraScript::AuraEffectCalcAmountFnType)_pEffectHandlerScript, _effIndex, _effName) { } }; \
class EffectCalcPeriodicHandlerFunction : public AuraScript::EffectCalcPeriodicHandler { public: explicit EffectCalcPeriodicHandlerFunction(AuraEffectCalcPeriodicFnType _pEffectHandlerScript, uint8 _effIndex, uint16 _effName) : AuraScript::EffectCalcPeriodicHandler((AuraScript::AuraEffectCalcPeriodicFnType)_pEffectHandlerScript, _effIndex, _effName) { } }; \
class EffectCalcSpellModHandlerFunction : public AuraScript::EffectCalcSpellModHandler { public: explicit EffectCalcSpellModHandlerFunction(AuraEffectCalcSpellModFnType _pEffectHandlerScript, uint8 _effIndex, uint16 _effName) : AuraScript::EffectCalcSpellModHandler((AuraScript::AuraEffectCalcSpellModFnType)_pEffectHandlerScript, _effIndex, _effName) { } }; \
class EffectCalcCritChanceHandlerFunction : public AuraScript::EffectCalcCritChanceHandler { public: explicit EffectCalcCritChanceHandlerFunction(AuraEffectCalcCritChanceFnType effectHandlerScript, uint8 effIndex, uint16 effName) : AuraScript::EffectCalcCritChanceHandler((AuraScript::AuraEffectCalcCritChanceFnType)effectHandlerScript, effIndex, effName) { } }; \
class EffectApplyHandlerFunction : public AuraScript::EffectApplyHandler { public: explicit EffectApplyHandlerFunction(AuraEffectApplicationModeFnType _pEffectHandlerScript, uint8 _effIndex, uint16 _effName, AuraEffectHandleModes _mode) : AuraScript::EffectApplyHandler((AuraScript::AuraEffectApplicationModeFnType)_pEffectHandlerScript, _effIndex, _effName, _mode) { } }; \
class EffectAbsorbFunction : public AuraScript::EffectAbsorbHandler { public: explicit EffectAbsorbFunction(AuraEffectAbsorbFnType _pEffectHandlerScript, uint8 _effIndex, bool overkill = false) : AuraScript::EffectAbsorbHandler((AuraScript::AuraEffectAbsorbFnType)_pEffectHandlerScript, _effIndex, overkill) { } }; \
class EffectManaShieldFunction : public AuraScript::EffectManaShieldHandler { public: explicit EffectManaShieldFunction(AuraEffectAbsorbFnType _pEffectHandlerScript, uint8 _effIndex) : AuraScript::EffectManaShieldHandler((AuraScript::AuraEffectAbsorbFnType)_pEffectHandlerScript, _effIndex) { } }; \
class EffectSplitFunction : public AuraScript::EffectSplitHandler { public: explicit EffectSplitFunction(AuraEffectSplitFnType _pEffectHandlerScript, uint8 _effIndex) : AuraScript::EffectSplitHandler((AuraScript::AuraEffectSplitFnType)_pEffectHandlerScript, _effIndex) { } }; \
class CheckProcHandlerFunction : public AuraScript::CheckProcHandler { public: explicit CheckProcHandlerFunction(AuraCheckProcFnType handlerScript) : AuraScript::CheckProcHandler((AuraScript::AuraCheckProcFnType)handlerScript) { } }; \
class CheckEffectProcHandlerFunction : public AuraScript::CheckEffectProcHandler { public: explicit CheckEffectProcHandlerFunction(AuraCheckEffectProcFnType handlerScript, uint8 effIndex, uint16 effName) : AuraScript::CheckEffectProcHandler((AuraScript::AuraCheckEffectProcFnType)handlerScript, effIndex, effName) { } }; \
class AuraProcHandlerFunction : public AuraScript::AuraProcHandler { public: explicit AuraProcHandlerFunction(AuraProcFnType handlerScript) : AuraScript::AuraProcHandler((AuraScript::AuraProcFnType)handlerScript) { } }; \
class EffectProcHandlerFunction : public AuraScript::EffectProcHandler { public: explicit EffectProcHandlerFunction(AuraEffectProcFnType effectHandlerScript, uint8 effIndex, uint16 effName) : AuraScript::EffectProcHandler((AuraScript::AuraEffectProcFnType)effectHandlerScript, effIndex, effName) { } }; \
class EnterLeaveCombatFunction : public AuraScript::EnterLeaveCombatHandler { public: explicit EnterLeaveCombatFunction(AuraEnterLeaveCombatFnType handlerScript) : AuraScript::EnterLeaveCombatHandler((AuraScript::AuraEnterLeaveCombatFnType)handlerScript) { } }
Definition: SpellScript.h:843
Definition: SpellScript.h:803
Definition: SpellScript.h:895
AuraEffectHandleModes
Definition: SpellAuraDefines.h:47
Definition: SpellScript.h:751
Definition: SpellScript.h:830
Definition: SpellScript.h:908
Definition: SpellScript.h:856
Definition: SpellScript.h:921
Definition: SpellScript.h:777
uint16_t uint16
Definition: Define.h:144
Definition: SpellScript.h:869
Definition: SpellScript.h:790
Definition: SpellScript.h:882
uint8_t uint8
Definition: Define.h:145
Definition: SpellScript.h:738
Definition: SpellScript.h:713
Definition: SpellScript.h:674
Definition: SpellScript.h:816
Definition: SpellScript.h:764
Definition: SpellScript.h:700

◆ AURASCRIPT_FUNCTION_TYPE_DEFINES

#define AURASCRIPT_FUNCTION_TYPE_DEFINES (   CLASSNAME)
Value:
typedef bool(CLASSNAME::*AuraCheckAreaTargetFnType)(Unit* target); \
typedef void(CLASSNAME::*AuraDispelFnType)(DispelInfo* dispelInfo); \
typedef void(CLASSNAME::*AuraEffectApplicationModeFnType)(AuraEffect const*, AuraEffectHandleModes); \
typedef void(CLASSNAME::*AuraEffectPeriodicFnType)(AuraEffect const*); \
typedef void(CLASSNAME::*AuraEffectUpdatePeriodicFnType)(AuraEffect*); \
typedef void(CLASSNAME::*AuraEffectCalcAmountFnType)(AuraEffect const*, int32 &, bool &); \
typedef void(CLASSNAME::*AuraEffectCalcPeriodicFnType)(AuraEffect const*, bool &, int32 &); \
typedef void(CLASSNAME::*AuraEffectCalcSpellModFnType)(AuraEffect const*, SpellModifier* &); \
typedef void(CLASSNAME::*AuraEffectCalcCritChanceFnType)(AuraEffect const*, Unit const*, float&); \
typedef void(CLASSNAME::*AuraEffectAbsorbFnType)(AuraEffect*, DamageInfo &, uint32 &); \
typedef void(CLASSNAME::*AuraEffectSplitFnType)(AuraEffect*, DamageInfo &, uint32 &); \
typedef bool(CLASSNAME::*AuraCheckProcFnType)(ProcEventInfo&); \
typedef bool(CLASSNAME::*AuraCheckEffectProcFnType)(AuraEffect const*, ProcEventInfo&); \
typedef void(CLASSNAME::*AuraProcFnType)(ProcEventInfo&); \
typedef void(CLASSNAME::*AuraEffectProcFnType)(AuraEffect*, ProcEventInfo&); \
typedef void(CLASSNAME::*AuraEnterLeaveCombatFnType)(bool);
Definition: SpellAuraEffects.h:28
AuraEffectHandleModes
Definition: SpellAuraDefines.h:47
Definition: Player.h:253
Definition: Unit.h:483
int32_t int32
Definition: Define.h:139
uint32_t uint32
Definition: Define.h:143
Definition: Unit.h:381
Definition: Unit.h:746
Definition: Unit.h:412

◆ BeforeSpellHitFn

#define BeforeSpellHitFn (   F)    BeforeHitHandlerFunction(&F)

◆ HOOK_SPELL_HIT_END

#define HOOK_SPELL_HIT_END   SPELL_SCRIPT_HOOK_AFTER_HIT + 1

◆ HOOK_SPELL_HIT_START

#define HOOK_SPELL_HIT_START   SPELL_SCRIPT_HOOK_EFFECT_HIT

◆ PrepareAuraScript

#define PrepareAuraScript (   CLASSNAME)    AURASCRIPT_FUNCTION_TYPE_DEFINES(CLASSNAME) AURASCRIPT_FUNCTION_CAST_DEFINES(CLASSNAME)

◆ PrepareSpellScript

#define PrepareSpellScript (   CLASSNAME)    SPELLSCRIPT_FUNCTION_TYPE_DEFINES(CLASSNAME) SPELLSCRIPT_FUNCTION_CAST_DEFINES(CLASSNAME)

◆ SPELL_AURA_ANY

#define SPELL_AURA_ANY   (uint16)-1

◆ SPELL_EFFECT_ANY

#define SPELL_EFFECT_ANY   (uint16)-1

◆ SPELL_SCRIPT_STATE_END

#define SPELL_SCRIPT_STATE_END   SPELL_SCRIPT_STATE_UNLOADING + 1

◆ SpellCastFn

#define SpellCastFn (   F)    CastHandlerFunction(&F)

◆ SpellCheckCastFn

#define SpellCheckCastFn (   F)    CheckCastHandlerFunction(&F)

◆ SpellDestinationTargetSelectFn

#define SpellDestinationTargetSelectFn (   F,
  I,
 
)    DestinationTargetSelectHandlerFunction(&F, I, N)

◆ SpellEffectFn

#define SpellEffectFn (   F,
  I,
 
)    EffectHandlerFunction(&F, I, N)

◆ SpellHitFn

#define SpellHitFn (   F)    HitHandlerFunction(&F)

◆ SpellObjectAreaTargetSelectFn

#define SpellObjectAreaTargetSelectFn (   F,
  I,
 
)    ObjectAreaTargetSelectHandlerFunction(&F, I, N)

◆ SpellObjectTargetSelectFn

#define SpellObjectTargetSelectFn (   F,
  I,
 
)    ObjectTargetSelectHandlerFunction(&F, I, N)

◆ SpellOnCalcCritChanceFn

#define SpellOnCalcCritChanceFn (   F)    OnCalcCritChanceHandlerFunction(&F)

◆ SpellOnResistAbsorbCalculateFn

#define SpellOnResistAbsorbCalculateFn (   F)    OnCalculateResistAbsorbHandlerFunction(&F)

◆ SPELLSCRIPT_FUNCTION_CAST_DEFINES

#define SPELLSCRIPT_FUNCTION_CAST_DEFINES (   CLASSNAME)
Value:
class CastHandlerFunction : public SpellScript::CastHandler { public: explicit CastHandlerFunction(SpellCastFnType _pCastHandlerScript) : SpellScript::CastHandler((SpellScript::SpellCastFnType)_pCastHandlerScript) { } }; \
class CheckCastHandlerFunction : public SpellScript::CheckCastHandler { public: explicit CheckCastHandlerFunction(SpellCheckCastFnType _checkCastHandlerScript) : SpellScript::CheckCastHandler((SpellScript::SpellCheckCastFnType)_checkCastHandlerScript) { } }; \
class EffectHandlerFunction : public SpellScript::EffectHandler { public: explicit EffectHandlerFunction(SpellEffectFnType _pEffectHandlerScript, uint8 _effIndex, uint16 _effName) : SpellScript::EffectHandler((SpellScript::SpellEffectFnType)_pEffectHandlerScript, _effIndex, _effName) { } }; \
class HitHandlerFunction : public SpellScript::HitHandler { public: explicit HitHandlerFunction(SpellHitFnType _pHitHandlerScript) : SpellScript::HitHandler((SpellScript::SpellHitFnType)_pHitHandlerScript) { } }; \
class BeforeHitHandlerFunction : public SpellScript::BeforeHitHandler { public: explicit BeforeHitHandlerFunction(SpellBeforeHitFnType pBeforeHitHandlerScript) : SpellScript::BeforeHitHandler((SpellScript::SpellBeforeHitFnType)pBeforeHitHandlerScript) { } }; \
class OnCalcCritChanceHandlerFunction : public SpellScript::OnCalcCritChanceHandler { public: explicit OnCalcCritChanceHandlerFunction(SpellOnCalcCritChanceFnType onCalcCritChanceHandlerScript) : SpellScript::OnCalcCritChanceHandler((SpellScript::SpellOnCalcCritChanceFnType)onCalcCritChanceHandlerScript) {} }; \
class OnCalculateResistAbsorbHandlerFunction : public SpellScript::OnCalculateResistAbsorbHandler { public: explicit OnCalculateResistAbsorbHandlerFunction(SpellOnResistAbsorbCalculateFnType _onCalculateResistAbsorbScript) : SpellScript::OnCalculateResistAbsorbHandler((SpellScript::SpellOnResistAbsorbCalculateFnType)_onCalculateResistAbsorbScript) { } }; \
class ObjectAreaTargetSelectHandlerFunction : public SpellScript::ObjectAreaTargetSelectHandler { public: explicit ObjectAreaTargetSelectHandlerFunction(SpellObjectAreaTargetSelectFnType _pObjectAreaTargetSelectHandlerScript, uint8 _effIndex, uint16 _targetType) : SpellScript::ObjectAreaTargetSelectHandler((SpellScript::SpellObjectAreaTargetSelectFnType)_pObjectAreaTargetSelectHandlerScript, _effIndex, _targetType) { } }; \
class ObjectTargetSelectHandlerFunction : public SpellScript::ObjectTargetSelectHandler { public: explicit ObjectTargetSelectHandlerFunction(SpellObjectTargetSelectFnType _pObjectTargetSelectHandlerScript, uint8 _effIndex, uint16 _targetType) : SpellScript::ObjectTargetSelectHandler((SpellScript::SpellObjectTargetSelectFnType)_pObjectTargetSelectHandlerScript, _effIndex, _targetType) { } }; \
class DestinationTargetSelectHandlerFunction : public SpellScript::DestinationTargetSelectHandler { public: explicit DestinationTargetSelectHandlerFunction(SpellDestinationTargetSelectFnType _DestinationTargetSelectHandlerScript, uint8 _effIndex, uint16 _targetType) : SpellScript::DestinationTargetSelectHandler((SpellScript::SpellDestinationTargetSelectFnType)_DestinationTargetSelectHandlerScript, _effIndex, _targetType) { } };
Definition: SpellScript.h:243
Definition: SpellScript.h:301
Definition: SpellScript.h:224
Definition: SpellScript.h:315
Definition: SpellScript.h:271
Definition: SpellScript.h:375
Definition: SpellScript.h:257
uint16_t uint16
Definition: Define.h:144
Definition: SpellScript.h:347
Definition: SpellScript.h:287
uint8_t uint8
Definition: Define.h:145
Definition: SpellScript.h:361
Definition: SpellScript.h:389

◆ SPELLSCRIPT_FUNCTION_TYPE_DEFINES

#define SPELLSCRIPT_FUNCTION_TYPE_DEFINES (   CLASSNAME)
Value:
typedef SpellCastResult(CLASSNAME::*SpellCheckCastFnType)(); \
typedef void(CLASSNAME::*SpellEffectFnType)(SpellEffIndex); \
typedef void(CLASSNAME::*SpellBeforeHitFnType)(SpellMissInfo missInfo); \
typedef void(CLASSNAME::*SpellHitFnType)(); \
typedef void(CLASSNAME::*SpellCastFnType)(); \
typedef void(CLASSNAME::*SpellOnCalcCritChanceFnType)(Unit const* victim, float& chance); \
typedef void(CLASSNAME::*SpellOnResistAbsorbCalculateFnType)(DamageInfo const& damageInfo, uint32& resistAmount, int32& absorbAmount); \
typedef void(CLASSNAME::*SpellObjectAreaTargetSelectFnType)(std::list<WorldObject*>&); \
typedef void(CLASSNAME::*SpellObjectTargetSelectFnType)(WorldObject*&); \
typedef void(CLASSNAME::*SpellDestinationTargetSelectFnType)(SpellDestination&);
SpellMissInfo
Definition: SharedDefines.h:2684
Definition: Object.h:430
SpellEffIndex
Definition: SharedDefines.h:27
Definition: SpellDefines.h:305
int32_t int32
Definition: Define.h:139
uint32_t uint32
Definition: Define.h:143
SpellCastResult
Definition: SharedDefines.h:1442
Definition: Unit.h:746
Definition: Unit.h:412

Enumeration Type Documentation

◆ AuraScriptHookType

Enumerator
AURA_SCRIPT_HOOK_EFFECT_APPLY 
AURA_SCRIPT_HOOK_EFFECT_AFTER_APPLY 
AURA_SCRIPT_HOOK_EFFECT_REMOVE 
AURA_SCRIPT_HOOK_EFFECT_AFTER_REMOVE 
AURA_SCRIPT_HOOK_EFFECT_PERIODIC 
AURA_SCRIPT_HOOK_EFFECT_UPDATE_PERIODIC 
AURA_SCRIPT_HOOK_EFFECT_CALC_AMOUNT 
AURA_SCRIPT_HOOK_EFFECT_CALC_PERIODIC 
AURA_SCRIPT_HOOK_EFFECT_CALC_SPELLMOD 
AURA_SCRIPT_HOOK_EFFECT_CALC_CRIT_CHANCE 
AURA_SCRIPT_HOOK_EFFECT_ABSORB 
AURA_SCRIPT_HOOK_EFFECT_AFTER_ABSORB 
AURA_SCRIPT_HOOK_EFFECT_MANASHIELD 
AURA_SCRIPT_HOOK_EFFECT_AFTER_MANASHIELD 
AURA_SCRIPT_HOOK_EFFECT_SPLIT 
AURA_SCRIPT_HOOK_CHECK_AREA_TARGET 
AURA_SCRIPT_HOOK_DISPEL 
AURA_SCRIPT_HOOK_AFTER_DISPEL 
AURA_SCRIPT_HOOK_ENTER_LEAVE_COMBAT 
AURA_SCRIPT_HOOK_CHECK_PROC 
AURA_SCRIPT_HOOK_CHECK_EFFECT_PROC 
AURA_SCRIPT_HOOK_PREPARE_PROC 
AURA_SCRIPT_HOOK_PROC 
AURA_SCRIPT_HOOK_EFFECT_PROC 
AURA_SCRIPT_HOOK_EFFECT_AFTER_PROC 
AURA_SCRIPT_HOOK_AFTER_PROC 
638 {
658  // Spell Proc Hooks
666  /*AURA_SCRIPT_HOOK_APPLY,
667  AURA_SCRIPT_HOOK_REMOVE, */
668 };
Definition: SpellScript.h:653
#define SPELL_SCRIPT_STATE_END
Definition: SpellScript.h:67
Definition: SpellScript.h:639
Definition: SpellScript.h:656
Definition: SpellScript.h:659
Definition: SpellScript.h:650
Definition: SpellScript.h:662
Definition: SpellScript.h:649
Definition: SpellScript.h:654
Definition: SpellScript.h:640
Definition: SpellScript.h:641
Definition: SpellScript.h:648
Definition: SpellScript.h:643
Definition: SpellScript.h:642
Definition: SpellScript.h:664
Definition: SpellScript.h:665
Definition: SpellScript.h:644
Definition: SpellScript.h:647
Definition: SpellScript.h:657
Definition: SpellScript.h:661
Definition: SpellScript.h:651
Definition: SpellScript.h:660
Definition: SpellScript.h:646
Definition: SpellScript.h:655
Definition: SpellScript.h:663
Definition: SpellScript.h:645
Definition: SpellScript.h:652

◆ SpellScriptHookType

Enumerator
SPELL_SCRIPT_HOOK_EFFECT_LAUNCH 
SPELL_SCRIPT_HOOK_EFFECT_LAUNCH_TARGET 
SPELL_SCRIPT_HOOK_EFFECT_HIT 
SPELL_SCRIPT_HOOK_EFFECT_HIT_TARGET 
SPELL_SCRIPT_HOOK_EFFECT_SUCCESSFUL_DISPEL 
SPELL_SCRIPT_HOOK_BEFORE_HIT 
SPELL_SCRIPT_HOOK_HIT 
SPELL_SCRIPT_HOOK_AFTER_HIT 
SPELL_SCRIPT_HOOK_OBJECT_AREA_TARGET_SELECT 
SPELL_SCRIPT_HOOK_OBJECT_TARGET_SELECT 
SPELL_SCRIPT_HOOK_DESTINATION_TARGET_SELECT 
SPELL_SCRIPT_HOOK_CHECK_CAST 
SPELL_SCRIPT_HOOK_BEFORE_CAST 
SPELL_SCRIPT_HOOK_ON_CAST 
SPELL_SCRIPT_HOOK_ON_RESIST_ABSORB_CALCULATION 
SPELL_SCRIPT_HOOK_AFTER_CAST 
SPELL_SCRIPT_HOOK_CALC_CRIT_CHANCE 
SPELL_SCRIPT_HOOK_ON_PRECAST 
200 {
219 };
Definition: SpellScript.h:207
Definition: SpellScript.h:210
Definition: SpellScript.h:203
#define SPELL_SCRIPT_STATE_END
Definition: SpellScript.h:67
Definition: SpellScript.h:208
Definition: SpellScript.h:202
Definition: SpellScript.h:205
Definition: SpellScript.h:214
Definition: SpellScript.h:206
Definition: SpellScript.h:204
Definition: SpellScript.h:211
Definition: SpellScript.h:209
Definition: SpellScript.h:213
Definition: SpellScript.h:216
Definition: SpellScript.h:218
Definition: SpellScript.h:201
Definition: SpellScript.h:217
Definition: SpellScript.h:212

◆ SpellScriptState

Enumerator
SPELL_SCRIPT_STATE_NONE 
SPELL_SCRIPT_STATE_REGISTRATION 
SPELL_SCRIPT_STATE_LOADING 
SPELL_SCRIPT_STATE_UNLOADING 
61 {
66 };
Definition: SpellScript.h:63
Definition: SpellScript.h:62
Definition: SpellScript.h:64
Definition: SpellScript.h:65