Project SkyFire Core
SkyFire 5.4.8 server core API documentation
Loading...
Searching...
No Matches
Spell Class Reference

#include <Spell.h>

Collaboration diagram for Spell:

Classes

struct  GOTargetInfo
struct  HitTriggerSpell
struct  ItemTargetInfo
struct  TargetInfo

Public Types

typedef std::set< Aura * > UsedSpellMods

Public Member Functions

void _handle_finish_phase ()
void _handle_immediate_phase ()
int32 CalculateDamage (uint8 i, Unit const *target) const
bool CanAutoCast (Unit *target)
void cancel ()
void cast (bool skipCheck=false)
SpellCastResult CheckArenaAndRatedBattlegroundCastRules ()
SpellCastResult CheckCast (bool strict)
SpellCastResult CheckCasterAuras () const
void CheckDst ()
bool CheckEffectTarget (Unit const *target, uint32 eff) const
SpellCastResult CheckItems ()
SpellCastResult CheckPetCast (Unit *target)
SpellCastResult CheckPower ()
SpellCastResult CheckRange (bool strict)
SpellCastResult CheckRuneCost (uint32 runeCostID)
void CheckSrc ()
void CleanupTargetList ()
void Delayed ()
void DelayedChannel ()
void DoCreateItem (uint32 i, uint32 itemtype)
void EffectActivateObject (SpellEffIndex effIndex)
void EffectActivateRune (SpellEffIndex effIndex)
void EffectActivateSpec (SpellEffIndex effIndex)
void EffectAddComboPoints (SpellEffIndex effIndex)
void EffectAddExtraAttacks (SpellEffIndex effIndex)
void EffectAddFarsight (SpellEffIndex effIndex)
void EffectApplyAreaAura (SpellEffIndex effIndex)
void EffectApplyAura (SpellEffIndex effIndex)
void EffectApplyGlyph (SpellEffIndex effIndex)
void EffectBattlePetsUnlock (SpellEffIndex effIndex)
void EffectBind (SpellEffIndex effIndex)
void EffectBlock (SpellEffIndex effIndex)
void EffectCastButtons (SpellEffIndex effIndex)
void EffectCharge (SpellEffIndex effIndex)
void EffectChargeDest (SpellEffIndex effIndex)
void EffectCreateAreaTrigger (SpellEffIndex effIndex)
void EffectCreateItem (SpellEffIndex effIndex)
void EffectCreateItem2 (SpellEffIndex effIndex)
void EffectCreateRandomItem (SpellEffIndex effIndex)
void EffectCreateTamedPet (SpellEffIndex effIndex)
void EffectDamageFromMaxHealthPCT (SpellEffIndex effIndex)
void EffectDestroyAllTotems (SpellEffIndex effIndex)
void EffectDestroyItem (SpellEffIndex effIndex)
void EffectDiscoverTaxi (SpellEffIndex effIndex)
void EffectDisEnchant (SpellEffIndex effIndex)
void EffectDismissPet (SpellEffIndex effIndex)
void EffectDispel (SpellEffIndex effIndex)
void EffectDispelMechanic (SpellEffIndex effIndex)
void EffectDistract (SpellEffIndex effIndex)
void EffectDodge (SpellEffIndex effIndex)
void EffectDualWield (SpellEffIndex effIndex)
void EffectDuel (SpellEffIndex effIndex)
void EffectDummy (SpellEffIndex effIndex)
void EffectDurabilityDamage (SpellEffIndex effIndex)
void EffectDurabilityDamagePCT (SpellEffIndex effIndex)
void EffectEnchantHeldItem (SpellEffIndex effIndex)
void EffectEnchantItemPerm (SpellEffIndex effIndex)
void EffectEnchantItemPrismatic (SpellEffIndex effIndex)
void EffectEnchantItemTmp (SpellEffIndex effIndex)
void EffectEnergize (SpellEffIndex effIndex)
void EffectEnergizePct (SpellEffIndex effIndex)
void EffectEnvironmentalDMG (SpellEffIndex effIndex)
void EffectFeedPet (SpellEffIndex effIndex)
void EffectForceCast (SpellEffIndex effIndex)
void EffectForceDeselect (SpellEffIndex effIndex)
void EffectGameObjectDamage (SpellEffIndex effIndex)
void EffectGameObjectRepair (SpellEffIndex effIndex)
void EffectGameObjectSetDestructionState (SpellEffIndex effIndex)
void EffectGiveCurrency (SpellEffIndex effIndex)
void EffectHeal (SpellEffIndex effIndex)
void EffectHealBattlePetPct (SpellEffIndex effIndex)
void EffectHealMaxHealth (SpellEffIndex effIndex)
void EffectHealMechanical (SpellEffIndex effIndex)
void EffectHealPct (SpellEffIndex effIndex)
void EffectHealthLeech (SpellEffIndex effIndex)
void EffectInebriate (SpellEffIndex effIndex)
void EffectInstaKill (SpellEffIndex effIndex)
void EffectInterruptCast (SpellEffIndex effIndex)
void EffectJump (SpellEffIndex effIndex)
void EffectJumpDest (SpellEffIndex effIndex)
void EffectKillCredit (SpellEffIndex effIndex)
void EffectKillCreditPersonal (SpellEffIndex effIndex)
void EffectKnockBack (SpellEffIndex effIndex)
void EffectLeap (SpellEffIndex effIndex)
void EffectLeapBack (SpellEffIndex effIndex)
void EffectLearnPetSpell (SpellEffIndex effIndex)
void EffectLearnSkill (SpellEffIndex effIndex)
void EffectLearnSpell (SpellEffIndex effIndex)
void EffectMilling (SpellEffIndex effIndex)
void EffectModifyThreatPercent (SpellEffIndex effIndex)
void EffectNULL (SpellEffIndex effIndex)
void EffectOpenLock (SpellEffIndex effIndex)
void EffectParry (SpellEffIndex effIndex)
void EffectPersistentAA (SpellEffIndex effIndex)
void EffectPickPocket (SpellEffIndex effIndex)
void EffectPlayMovie (SpellEffIndex effIndex)
void EffectPlayMusic (SpellEffIndex effIndex)
void EffectPlaySound (SpellEffIndex effIndex)
void EffectPowerBurn (SpellEffIndex effIndex)
void EffectPowerDrain (SpellEffIndex effIndex)
void EffectProficiency (SpellEffIndex effIndex)
void EffectProspecting (SpellEffIndex effIndex)
void EffectPull (SpellEffIndex effIndex)
void EffectPullTowards (SpellEffIndex effIndex)
void EffectQuestClear (SpellEffIndex effIndex)
void EffectQuestComplete (SpellEffIndex effIndex)
void EffectQuestFail (SpellEffIndex effIndex)
void EffectQuestStart (SpellEffIndex effIndex)
void EffectRechargeManaGem (SpellEffIndex effIndex)
void EffectRedirectThreat (SpellEffIndex effIndex)
void EffectRemoveAura (SpellEffIndex effIndex)
void EffectRemoveTalent (SpellEffIndex effIndex)
void EffectRenamePet (SpellEffIndex effIndex)
void EffectReputation (SpellEffIndex effIndex)
void EffectResurrect (SpellEffIndex effIndex)
void EffectResurrectNew (SpellEffIndex effIndex)
void EffectResurrectWithAura (SpellEffIndex effIndex)
void EffectSanctuary (SpellEffIndex effIndex)
void EffectSchoolDMG (SpellEffIndex effIndex)
void EffectScriptEffect (SpellEffIndex effIndex)
void EffectSelfResurrect (SpellEffIndex effIndex)
void EffectSendEvent (SpellEffIndex effIndex)
void EffectSendTaxi (SpellEffIndex effIndex)
void EffectSkill (SpellEffIndex effIndex)
void EffectSkinning (SpellEffIndex effIndex)
void EffectSkinPlayerCorpse (SpellEffIndex effIndex)
void EffectSpecCount (SpellEffIndex effIndex)
void EffectSpiritHeal (SpellEffIndex effIndex)
void EffectStealBeneficialBuff (SpellEffIndex effIndex)
void EffectStuck (SpellEffIndex effIndex)
void EffectSummonChangeItem (SpellEffIndex effIndex)
void EffectSummonDeadPet (SpellEffIndex effIndex)
void EffectSummonObject (SpellEffIndex effIndex)
void EffectSummonObjectWild (SpellEffIndex effIndex)
void EffectSummonPet (SpellEffIndex effIndex)
void EffectSummonPlayer (SpellEffIndex effIndex)
void EffectSummonRaFFriend (SpellEffIndex effIndex)
void EffectSummonType (SpellEffIndex effIndex)
void EffectTameCreature (SpellEffIndex effIndex)
void EffectTaunt (SpellEffIndex effIndex)
void EffectTeleportUnits (SpellEffIndex effIndex)
void EffectTeleUnitsFaceCaster (SpellEffIndex effIndex)
void EffectThreat (SpellEffIndex effIndex)
void EffectTitanGrip (SpellEffIndex effIndex)
void EffectTradeSkill (SpellEffIndex effIndex)
void EffectTransmitted (SpellEffIndex effIndex)
void EffectTriggerMissileSpell (SpellEffIndex effIndex)
void EffectTriggerRitualOfSummoning (SpellEffIndex effIndex)
void EffectTriggerSpell (SpellEffIndex effIndex)
void EffectUnlearnSpecialization (SpellEffIndex effIndex)
void EffectUnlockGuildVaultTab (SpellEffIndex effIndex)
void EffectUntrainTalents (SpellEffIndex effIndex)
void EffectUnused (SpellEffIndex effIndex)
void EffectWeaponDmg (SpellEffIndex effIndex)
void ExecuteLogEffectCreateItem (uint8 effIndex, uint32 entry)
void ExecuteLogEffectDestroyItem (uint8 effIndex, uint32 entry)
void ExecuteLogEffectDurabilityDamage (uint8 effIndex, Unit *victim, int32 itemId, int32 slot)
void ExecuteLogEffectExtraAttacks (uint8 effIndex, Unit *victim, uint32 attCount)
void ExecuteLogEffectInterruptCast (uint8 effIndex, Unit *victim, uint32 spellId)
void ExecuteLogEffectOpenLock (uint8 effIndex, Object *obj)
void ExecuteLogEffectResurrect (uint8 effIndex, Unit *target)
void ExecuteLogEffectSummonObject (uint8 effIndex, WorldObject *obj)
void ExecuteLogEffectTakeTargetPower (uint8 effIndex, Unit *target, uint32 powerType, uint32 powerTaken, float gainMultiplier)
void ExecuteLogEffectUnsummonObject (uint8 effIndex, WorldObject *obj)
void finish (bool ok=true)
UnitGetCaster () const
int32 GetCastTime () const
CurrentSpellTypes GetCurrentContainer () const
uint64 GetDelayMoment () const
uint64 GetDelayStart () const
UnitGetOriginalCaster () const
int32 GetPowerCost () const
int32 GetPowerType () const
uint32 GetSearcherTypeMask (SpellTargetObjectTypes objType, ConditionList *condList) const
SpellInfo const * GetSpellInfo () const
uint32 getState () const
uint64 handle_delayed (uint64 t_offset)
void handle_immediate ()
void HandleEffects (Unit *pUnitTarget, Item *pItemTarget, GameObject *pGOTarget, uint32 i, SpellEffectHandleMode mode)
void HandleHolyPower (Player *caster)
void HandleThreatSpells ()
bool HaveTargetsForEffect (uint8 effect) const
void InitExplicitTargets (SpellCastTargets const &targets)
bool IsAutoActionResetSpell () const
bool IsAutoRepeat () const
bool IsChannelActive () const
bool IsDeletable () const
bool IsInterruptable () const
bool IsNeedSendToClient () const
bool IsNextMeleeSwingSpell () const
bool IsTriggered () const
void prepare (SpellCastTargets const *targets, AuraEffect const *triggeredByAura=NULL)
void ReSetTimer ()
void SearchAreaTargets (std::list< WorldObject * > &targets, float range, Position const *position, Unit *referer, SpellTargetObjectTypes objectType, SpellTargetCheckTypes selectionType, ConditionList *condList)
void SearchChainTargets (std::list< WorldObject * > &targets, uint32 chainTargets, WorldObject *target, SpellTargetObjectTypes objectType, SpellTargetCheckTypes selectType, ConditionList *condList, bool isChainHeal)
WorldObjectSearchNearbyTarget (float range, SpellTargetObjectTypes objectType, SpellTargetCheckTypes selectionType, ConditionList *condList=NULL)
GameObjectSearchSpellFocus ()
template<class SEARCHER>
void SearchTargets (SEARCHER &searcher, uint32 containerMask, Unit *referer, Position const *pos, float radius)
void SelectEffectImplicitTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType, uint32 &processedEffectMask)
void SelectEffectTypeImplicitTargets (uint8 effIndex)
void SelectExplicitTargets ()
void SelectImplicitAreaTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType, uint32 effMask)
void SelectImplicitCasterDestTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType)
void SelectImplicitCasterObjectTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType)
void SelectImplicitChainTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType, WorldObject *target, uint32 effMask)
void SelectImplicitChannelTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType)
void SelectImplicitConeTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType, uint32 effMask)
void SelectImplicitDestDestTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType)
void SelectImplicitNearbyTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType, uint32 effMask)
void SelectImplicitTargetDestTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType)
void SelectImplicitTargetObjectTargets (SpellEffIndex effIndex, SpellImplicitTargetInfo const &targetType)
void SelectImplicitTrajTargets ()
void SelectSpellTargets ()
void SendCastResult (SpellCastResult result)
void SendChannelStart (uint32 duration)
void SendChannelUpdate (uint32 time)
void SendInterrupted (uint8 result)
void SendLogExecute ()
void SendPetCastResult (SpellCastResult result)
void SendResurrectRequest (Player *target)
void SendSpellCooldown ()
void SendSpellGo ()
void SendSpellStart ()
void SetAutoRepeat (bool rep)
void SetDelayStart (uint64 m_time)
void SetExecutedCurrently (bool yes)
void SetReferencedFromCurrent (bool yes)
void SetSpellValue (SpellValueMod mod, int32 value)
void setState (uint32 state)
 Spell (Unit *caster, SpellInfo const *info, TriggerCastFlags triggerFlags, uint64 originalCasterGUID=0, bool skipCheck=false)
void TakeCastItem ()
void TakePower ()
void TakeReagents ()
void TakeRunePower (bool didHit)
void update (uint32 difftime)
void UpdatePointers ()
 ~Spell ()

Static Public Member Functions

static void SendCastResult (Player *caster, SpellInfo const *spellInfo, uint8 cast_count, SpellCastResult result, SpellCustomErrors customError=SPELL_CUSTOM_ERROR_NONE, Opcodes opcode=SMSG_CAST_FAILED)

Public Attributes

UsedSpellMods m_appliedMods
uint8 m_cast_count
Itemm_CastItem
uint64 m_castItemGUID
int8 m_comboPointGain
SpellCustomErrors m_customError
uint32 m_glyphIndex
SpellResearchData const * m_researchData
SpellInfo const *const m_spellInfo
SpellCastTargets m_targets

Protected Types

typedef std::list< HitTriggerSpellHitTriggerSpellList
typedef std::map< uint32, SpellLogHelperLogHelperMap

Protected Member Functions

void AddDestTarget (SpellDestination const &dest, uint32 effIndex)
void AddGOTarget (GameObject *target, uint32 effectMask)
void AddItemTarget (Item *item, uint32 effectMask)
void AddUnitTarget (Unit *target, uint32 effectMask, bool checkIfValid=true, bool implicit=true)
void CalculateJumpSpeeds (uint8 i, float dist, float &speedxy, float &speedz)
void CallScriptAfterCastHandlers ()
void CallScriptAfterHitHandlers ()
void CallScriptBeforeCastHandlers ()
void CallScriptBeforeHitHandlers ()
SpellCastResult CallScriptCheckCastHandlers ()
bool CallScriptEffectHandlers (SpellEffIndex effIndex, SpellEffectHandleMode mode)
void CallScriptObjectAreaTargetSelectHandlers (std::list< WorldObject * > &targets, SpellEffIndex effIndex)
void CallScriptObjectTargetSelectHandlers (WorldObject *&target, SpellEffIndex effIndex)
void CallScriptOnCastHandlers ()
void CallScriptOnHitHandlers ()
void CancelGlobalCooldown ()
bool CanExecuteTriggersOnHit (uint32 effMask, SpellInfo const *triggeredByAura=NULL) const
SpellCastResult CanOpenLock (uint32 effIndex, uint32 lockid, SkillType &skillid, int32 &reqSkillValue, int32 &skillValue)
void CheckEffectExecuteData () const
bool CheckScriptEffectImplicitTargets (uint32 effIndex, uint32 effIndexToCheck)
void DoAllEffectOnLaunchTarget (TargetInfo &targetInfo, float *multiplier)
void DoAllEffectOnTarget (GOTargetInfo *target)
void DoAllEffectOnTarget (ItemTargetInfo *target)
void DoAllEffectOnTarget (TargetInfo *target)
SpellMissInfo DoSpellHitOnUnit (Unit *unit, uint32 effectMask, bool scaleAura)
void DoTriggersOnSpellHit (Unit *unit, uint32 effMask)
void FinishTargetProcessing ()
void HandleLaunchPhase ()
bool HasGlobalCooldown () const
bool isDelayableNoMore ()
bool IsValidDeadOrAliveTarget (Unit const *target) const
void LoadScripts ()
void prepareDataForTriggerSystem (AuraEffect const *triggeredByAura)
void PrepareScriptHitHandlers ()
void PrepareTargetProcessing ()
void PrepareTriggersExecutedOnHit ()
void SendLoot (uint64 guid, LootType loottype)
void SummonGuardian (uint32 i, uint32 entry, SummonPropertiesEntry const *properties, uint32 numSummons)
void TriggerGlobalCooldown ()
bool UpdateChanneledTargetList ()

Protected Attributes

TriggerCastFlags _triggeredCastFlags
int32 damage
WorldLocationdestTarget
SpellEffectHandleMode effectHandleMode
GameObjectfocusObject
GameObjectgameObjTarget
ItemitemTarget
uint8 m_applyMultiplierMask
WeaponAttackType m_attackType
uint8 m_auraScaleMask
bool m_autoRepeat
bool m_canReflect
Unit *const m_caster
int32 m_casttime
uint8 m_channelTargetEffectMask
int32 m_damage
float m_damageMultipliers [3]
uint8 m_delayAtDamageCount
uint64 m_delayMoment
uint64 m_delayStart
SpellDestination m_destTargets [MAX_SPELL_EFFECTS]
DiminishingGroup m_diminishGroup
DiminishingLevels m_diminishLevel
LogHelperMap m_effectExecuteData
bool m_executedCurrently
int32 m_healing
HitTriggerSpellList m_hitTriggerSpells
bool m_immediateHandled
std::list< SpellScript * > m_loadedScripts
bool m_needComboPoints
Unitm_originalCaster
uint64 m_originalCasterGUID
int32 m_periodicPowerCost
int32 m_periodicPowerTimer
int32 m_powerCost
int32 m_powerType
PathGenerator m_preGeneratedPath
uint32 m_procAttacker
uint32 m_procEx
uint32 m_procVictim
bool m_referencedFromCurrentSpell
uint8 m_runesState
Spell ** m_selfContainer
bool m_skipCheck
Auram_spellAura
SpellSchoolMask m_spellSchoolMask
uint32 m_spellState
SpellValue *const m_spellValue
int32 m_timer
SpellInfo const * m_triggeredByAuraSpell
std::list< GOTargetInfom_UniqueGOTargetInfo
std::list< ItemTargetInfom_UniqueItemInfo
std::list< TargetInfom_UniqueTargetInfo
UnitunitTarget

Private Member Functions

Spelloperator= (Spell const &right)=delete
 Spell (Spell const &right)=delete

Friends

class SpellScript
void Unit::SetCurrentCastedSpell (Spell *pSpell)

Detailed Description

Definition at line 288 of file Spell.h.

Member Typedef Documentation

◆ HitTriggerSpellList

typedef std::list<HitTriggerSpell> Spell::HitTriggerSpellList
protected

Definition at line 739 of file Spell.h.

◆ LogHelperMap

typedef std::map<uint32, SpellLogHelper> Spell::LogHelperMap
protected

Definition at line 763 of file Spell.h.

◆ UsedSpellMods

typedef std::set<Aura*> Spell::UsedSpellMods

Definition at line 428 of file Spell.h.

Constructor & Destructor Documentation

◆ Spell() [1/2]

◆ ~Spell()

◆ Spell() [2/2]

Spell::Spell ( Spell const & right)
privatedelete

References Spell().

Member Function Documentation

◆ _handle_finish_phase()

void Spell::_handle_finish_phase ( )

◆ _handle_immediate_phase()

◆ AddDestTarget()

void Spell::AddDestTarget ( SpellDestination const & dest,
uint32 effIndex )
protected

Definition at line 2340 of file Spell.cpp.

References m_destTargets.

Referenced by SelectSpellTargets().

◆ AddGOTarget()

◆ AddItemTarget()

void Spell::AddItemTarget ( Item * item,
uint32 effectMask )
protected

◆ AddUnitTarget()

◆ CalculateDamage()

int32 Spell::CalculateDamage ( uint8 i,
Unit const * target ) const
inline

Definition at line 489 of file Spell.h.

References m_caster, m_spellInfo, and m_spellValue.

Referenced by CheckCast(), CheckEffectTarget(), EffectWeaponDmg(), and HandleEffects().

◆ CalculateJumpSpeeds()

void Spell::CalculateJumpSpeeds ( uint8 i,
float dist,
float & speedxy,
float & speedz )
protected

Definition at line 110 of file SpellEffectsMovement.cpp.

References m_spellInfo.

Referenced by EffectJump(), and EffectJumpDest().

◆ CallScriptAfterCastHandlers()

void Spell::CallScriptAfterCastHandlers ( )
protected

Definition at line 7744 of file Spell.cpp.

References m_loadedScripts, and SPELL_SCRIPT_HOOK_AFTER_CAST.

Referenced by cast().

◆ CallScriptAfterHitHandlers()

void Spell::CallScriptAfterHitHandlers ( )
protected

◆ CallScriptBeforeCastHandlers()

void Spell::CallScriptBeforeCastHandlers ( )
protected

Definition at line 7718 of file Spell.cpp.

References m_loadedScripts, and SPELL_SCRIPT_HOOK_BEFORE_CAST.

Referenced by cast().

◆ CallScriptBeforeHitHandlers()

void Spell::CallScriptBeforeHitHandlers ( )
protected

◆ CallScriptCheckCastHandlers()

SpellCastResult Spell::CallScriptCheckCastHandlers ( )
protected

Definition at line 7757 of file Spell.cpp.

References m_loadedScripts, SPELL_CAST_OK, and SPELL_SCRIPT_HOOK_CHECK_CAST.

Referenced by CheckCast().

◆ CallScriptEffectHandlers()

◆ CallScriptObjectAreaTargetSelectHandlers()

void Spell::CallScriptObjectAreaTargetSelectHandlers ( std::list< WorldObject * > & targets,
SpellEffIndex effIndex )
protected

◆ CallScriptObjectTargetSelectHandlers()

◆ CallScriptOnCastHandlers()

void Spell::CallScriptOnCastHandlers ( )
protected

Definition at line 7731 of file Spell.cpp.

References m_loadedScripts, and SPELL_SCRIPT_HOOK_ON_CAST.

Referenced by cast().

◆ CallScriptOnHitHandlers()

void Spell::CallScriptOnHitHandlers ( )
protected

◆ CanAutoCast()

◆ cancel()

◆ CancelGlobalCooldown()

void Spell::CancelGlobalCooldown ( )
protected

Definition at line 8013 of file Spell.cpp.

References CURRENT_GENERIC_SPELL, m_caster, m_spellInfo, and TYPEID_PLAYER.

Referenced by cancel().

◆ CanExecuteTriggersOnHit()

bool Spell::CanExecuteTriggersOnHit ( uint32 effMask,
SpellInfo const * triggeredByAura = NULL ) const
protected

◆ CanOpenLock()

◆ cast()

◆ CheckArenaAndRatedBattlegroundCastRules()

◆ CheckCast()

SpellCastResult Spell::CheckCast ( bool strict)
Todo
determine if there is some flag to enable/disable the check

Definition at line 5539 of file Spell.cpp.

References _triggeredCastFlags, InstanceTemplate::AllowMount, AREA_FLAG_NO_FLY_ZONE, AURA_INTERRUPT_FLAG_NOT_SEATED, CalculateDamage(), CallScriptCheckCastHandlers(), Battlefield::CanFlyIn(), CanOpenLock(), SummonPropertiesEntry::Category, CheckArenaAndRatedBattlegroundCastRules(), CheckCasterAuras(), CheckItems(), CheckPower(), CheckRange(), CLASS_WARLOCK, CONDITION_SOURCE_TYPE_SPELL, Condition::ConditionTarget, CONTACT_DISTANCE, VMAP::VMapFactory::createOrGetVMapManager(), CREATURE_TYPE_CRITTER, damage, DISABLE_TYPE_SPELL, Condition::ErrorTextId, Condition::ErrorType, ObjectAccessor::FindPlayer(), focusObject, GAMEOBJECT_TYPE_TRAP, WorldSession::GetAccountId(), GetAreaEntryByAreaID(), Unit::getAttackers(), Player::GetBoundInstance(), Unit::GetCharmerGUID(), WorldObject::GetContactPoint(), Creature::GetCreatureTemplate(), Unit::GetCreatureType(), Pet::GetCurrentFoodBenefitLevel(), WorldObject::GetFirstCollisionPosition(), Unit::getLevel(), WorldObject::GetObjectSize(), Pet::GetOwner(), WorldSession::GetRecruiterId(), Position::GetRelativeAngle(), CreatureTemplate::GetRequiredLootSkill(), Player::GetSelectedPlayer(), Player::GetSession(), TradeData::GetSpell(), GetSpellInfo(), Unit::GetTarget(), Item::GetTemplate(), Unit::HasAura(), HasGlobalCooldown(), Pet::HaveInDiet(), Unit::IsAlive(), IsAutoRepeat(), DisableMgr::IsDisabledFor(), Unit::IsFriendlyTo(), Unit::IsInCombat(), Player::IsInSameRaidWith(), MapEntry::IsInstance(), Item::IsLocked(), Loot::isLooted(), MapEntry::IsRaid(), IsTriggered(), ItemTemplate::ItemLevel, ItemTemplate::LockID, Creature::loot, m_caster, m_CastItem, m_customError, m_needComboPoints, m_originalCaster, M_PI, Position::m_positionX, Position::m_positionY, Position::m_positionZ, m_preGeneratedPath, m_selfContainer, m_spellInfo, m_targets, m_triggeredByAuraSpell, MAX_SPELL_EFFECTS, ConditionSourceInfo::mConditionTargets, ConditionSourceInfo::mLastFailedCondition, MOVEMENTFLAG_FALLING_FAR, PATHFIND_NOPATH, PATHFIND_SHORT, PLAYER_FIELD_PLAYER_FLAGS, PLAYER_FLAGS_ALLOW_ONLY_ABILITY, POWER_MANA, Player::Satisfy(), sBattlefieldMgr, sConditionMgr, SearchSpellFocus(), sGlyphPropertiesStore, SKILL_HERBALISM, SKILL_MINING, SKILL_NONE, sMapStore, sObjectMgr, SPELL_ATTR0_CASTABLE_WHILE_DEAD, SPELL_ATTR0_CASTABLE_WHILE_MOUNTED, SPELL_ATTR0_CU_REQ_CASTER_BEHIND_TARGET, SPELL_ATTR0_CU_REQ_TARGET_FACING_CASTER, SPELL_ATTR0_INDOORS_ONLY, SPELL_ATTR0_ONLY_STEALTHED, SPELL_ATTR0_OUTDOORS_ONLY, SPELL_ATTR0_PASSIVE, SPELL_ATTR2_CAN_TARGET_NOT_IN_LOS, SPELL_ATTR3_BATTLEGROUND, SPELL_ATTR7_IS_CHEAT_SPELL, SPELL_AURA_ABILITY_IGNORE_AURASTATE, SPELL_AURA_AOE_CHARM, SPELL_AURA_BLOCK_SPELL_FAMILY, SPELL_AURA_CAST_WHILE_WALKING, SPELL_AURA_FLY, SPELL_AURA_MOD_CHARM, SPELL_AURA_MOD_IGNORE_SHAPESHIFT, SPELL_AURA_MOD_INCREASE_MOUNTED_FLIGHT_SPEED, SPELL_AURA_MOD_POSSESS, SPELL_AURA_MOD_POSSESS_PET, SPELL_AURA_MOUNTED, SPELL_AURA_PERIODIC_MANA_LEECH, SPELL_AURA_RANGED_ATTACK_POWER_ATTACKER_BONUS, SPELL_CAST_OK, SPELL_CUSTOM_ERROR_GM_ONLY, SPELL_DISABLE_LOS, SPELL_EFFECT_APPLY_GLYPH, SPELL_EFFECT_CHARGE, SPELL_EFFECT_CREATE_TAMED_PET, SPELL_EFFECT_DUMMY, SPELL_EFFECT_FEED_PET, SPELL_EFFECT_LEAP, SPELL_EFFECT_LEAP_BACK, SPELL_EFFECT_LEARN_PET_SPELL, SPELL_EFFECT_LEARN_SPELL, SPELL_EFFECT_OPEN_LOCK, SPELL_EFFECT_POWER_BURN, SPELL_EFFECT_POWER_DRAIN, SPELL_EFFECT_RESURRECT_PET, SPELL_EFFECT_SKINNING, SPELL_EFFECT_STEAL_BENEFICIAL_BUFF, SPELL_EFFECT_STUCK, SPELL_EFFECT_SUMMON, SPELL_EFFECT_SUMMON_PET, SPELL_EFFECT_SUMMON_PLAYER, SPELL_EFFECT_SUMMON_RAF_FRIEND, SPELL_EFFECT_TALENT_SPEC_SELECT, SPELL_EFFECT_TELEPORT_UNITS_FACE_CASTER, SPELL_EFFECT_UNLOCK_GUILD_VAULT_TAB, SPELL_FAILED_AFFECTING_COMBAT, SPELL_FAILED_ALREADY_HAVE_CHARM, SPELL_FAILED_ALREADY_HAVE_SUMMON, SPELL_FAILED_BAD_IMPLICIT_TARGETS, SPELL_FAILED_BAD_TARGETS, SPELL_FAILED_CANT_BE_CHARMED, SPELL_FAILED_CANT_DO_THAT_RIGHT_NOW, SPELL_FAILED_CASTER_AURASTATE, SPELL_FAILED_CASTER_DEAD, SPELL_FAILED_CHARMED, SPELL_FAILED_CUSTOM_ERROR, SPELL_FAILED_DONT_REPORT, SPELL_FAILED_FOOD_LOWLEVEL, SPELL_FAILED_HIGHLEVEL, SPELL_FAILED_ITEM_ALREADY_ENCHANTED, SPELL_FAILED_ITEM_ENCHANT_TRADE_WINDOW, SPELL_FAILED_LINE_OF_SIGHT, SPELL_FAILED_LOW_CASTLEVEL, SPELL_FAILED_LOWLEVEL, SPELL_FAILED_MOVING, SPELL_FAILED_NO_COMBO_POINTS, SPELL_FAILED_NO_MOUNTS_ALLOWED, SPELL_FAILED_NO_PET, SPELL_FAILED_NOPATH, SPELL_FAILED_NOT_BEHIND, SPELL_FAILED_NOT_HERE, SPELL_FAILED_NOT_IN_BATTLEGROUND, SPELL_FAILED_NOT_INFRONT, SPELL_FAILED_NOT_KNOWN, SPELL_FAILED_NOT_MOUNTED, SPELL_FAILED_NOT_ON_TAXI, SPELL_FAILED_NOT_READY, SPELL_FAILED_NOT_SHAPESHIFT, SPELL_FAILED_NOT_TRADING, SPELL_FAILED_ONLY_ABOVEWATER, SPELL_FAILED_ONLY_BATTLEGROUNDS, SPELL_FAILED_ONLY_INDOORS, SPELL_FAILED_ONLY_OUTDOORS, SPELL_FAILED_ONLY_STEALTHED, SPELL_FAILED_OUT_OF_RANGE, SPELL_FAILED_REQUIRES_SPELL_FOCUS, SPELL_FAILED_ROOTED, SPELL_FAILED_SPELL_IN_PROGRESS, SPELL_FAILED_SPELL_UNAVAILABLE, SPELL_FAILED_SUCCESS, SPELL_FAILED_TARGET_FRIENDLY, SPELL_FAILED_TARGET_IS_PLAYER_CONTROLLED, SPELL_FAILED_TARGET_LOCKED_TO_RAID_INSTANCE, SPELL_FAILED_TARGET_NOT_IN_INSTANCE, SPELL_FAILED_TARGET_NOT_LOOTED, SPELL_FAILED_TARGET_UNSKINNABLE, SPELL_FAILED_TRY_AGAIN, SPELL_FAILED_UNIQUE_GLYPH, SPELL_FAILED_WRONG_PET_FOOD, sSpellMgr, sSummonPropertiesStore, STATUS_IN_PROGRESS, STATUS_WAIT_LEAVE, SUMMON_CATEGORY_PET, SUMMON_CATEGORY_PUPPET, TARGET_FLAG_ITEM, TARGET_FLAG_TRADE_ITEM, TARGET_GAMEOBJECT_ITEM_TARGET, TARGET_GAMEOBJECT_TARGET, TARGET_UNIT_PET, TRADE_SLOT_NONTRADED, TRIGGERED_DONT_REPORT_CAST_ERROR, TRIGGERED_IGNORE_CASTER_AURAS, TRIGGERED_IGNORE_CASTER_AURASTATE, TRIGGERED_IGNORE_CASTER_MOUNTED_OR_ON_VEHICLE, TRIGGERED_IGNORE_GCD, TRIGGERED_IGNORE_POWER_AND_REAGENT_COST, TRIGGERED_IGNORE_SHAPESHIFT, TYPEID_PLAYER, TYPEID_UNIT, UNIT_FIELD_FLAGS, UNIT_FIELD_FLAGS2, UNIT_FLAG2_ALLOW_CHEAT_SPELLS, UNIT_FLAG_SKINNABLE, UNIT_STATE_ROOT, unitTarget, and WORLD_TRIGGER.

Referenced by cast(), CheckPetCast(), WorldSession::HandleAcceptTradeOpcode(), and prepare().

◆ CheckCasterAuras()

◆ CheckDst()

void Spell::CheckDst ( )
inline

Definition at line 502 of file Spell.h.

References m_caster, and m_targets.

◆ CheckEffectExecuteData()

void Spell::CheckEffectExecuteData ( ) const
protected

Definition at line 7694 of file Spell.cpp.

References ASSERT, and m_effectExecuteData.

Referenced by PrepareTargetProcessing(), and ~Spell().

◆ CheckEffectTarget()

◆ CheckItems()

SpellCastResult Spell::CheckItems ( )
Todo
Needs review

Definition at line 6695 of file Spell.cpp.

References _triggeredCastFlags, BASE_ATTACK, Player::CanNoReagentCast(), Player::CanStoreNewItem(), Unit::CastSpell(), ItemTemplate::Class, ItemTemplate::DisenchantID, EFFECT_1, ENCHANTMENT_CAN_SOULBOUND, EQUIP_ERR_OK, Object::GetEntry(), Player::GetItemByEntry(), Item::GetOwner(), Player::GetSkillValue(), Item::GetTemplate(), Player::GetWeaponForAttack(), Player::HasItemCount(), Player::HasItemFitToSpellRequirements(), Item::IsBroken(), Item::IsFitToSpellRequirements(), IsTriggered(), ITEM_CLASS_ARMOR, ITEM_CLASS_CONSUMABLE, ITEM_CLASS_WEAPON, ITEM_ENCHANTMENT_TYPE_USE_SPELL, ITEM_PROTO_FLAG_MILLABLE, ITEM_PROTO_FLAG_PROSPECTABLE, ITEM_PROTO_FLAG_TRIGGERED_CAST, ITEM_SPELLTRIGGER_ON_NO_DELAY_USE, ITEM_SPELLTRIGGER_ON_USE, ITEM_SUBCLASS_WEAPON_BOW, ITEM_SUBCLASS_WEAPON_CROSSBOW, ITEM_SUBCLASS_WEAPON_GUN, ITEM_SUBCLASS_WEAPON_THROWN, ITEM_SUBCLASS_WEAPON_WAND, ItemTemplate::ItemLevel, ItemTemplate::ItemLimitCategory, LootTemplates_Milling, LootTemplates_Prospecting, m_attackType, m_caster, m_CastItem, m_castItemGUID, m_spellInfo, m_targets, MAX_ITEM_ENCHANTMENT_EFFECTS, MAX_ITEM_PROTO_SPELLS, MAX_ITEM_SPELLS, MAX_POWERS, MAX_SPELL_EFFECTS, MAX_SPELL_REAGENTS, NULL_BAG, NULL_SLOT, OFF_ATTACK, ItemTemplate::Quality, RANGED_ATTACK, ItemTemplate::RequiredDisenchantSkill, Player::SendEquipError(), SKILL_ENCHANTING, SKILL_INSCRIPTION, SKILL_JEWELCRAFTING, SpellItemEnchantmentEntry::slot, sObjectMgr, SPELL_ATTR3_MAIN_HAND, SPELL_ATTR3_REQ_OFFHAND, SPELL_CAST_OK, SPELL_EFFECT_CREATE_ITEM, SPELL_EFFECT_CREATE_ITEM_2, SPELL_EFFECT_CREATE_MANA_GEM, SPELL_EFFECT_DISENCHANT, SPELL_EFFECT_ENCHANT_HELD_ITEM, SPELL_EFFECT_ENCHANT_ITEM, SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC, SPELL_EFFECT_ENCHANT_ITEM_TEMPORARY, SPELL_EFFECT_ENERGIZE, SPELL_EFFECT_HEAL, SPELL_EFFECT_MILLING, SPELL_EFFECT_PROSPECTING, SPELL_EFFECT_WEAPON_DAMAGE, SPELL_EFFECT_WEAPON_DAMAGE_NOSCHOOL, SPELL_FAILED_ALREADY_AT_FULL_HEALTH, SPELL_FAILED_ALREADY_AT_FULL_POWER, SPELL_FAILED_CANT_BE_DISENCHANTED, SPELL_FAILED_CANT_BE_MILLED, SPELL_FAILED_CANT_BE_PROSPECTED, SPELL_FAILED_DONT_REPORT, SPELL_FAILED_EQUIPPED_ITEM, SPELL_FAILED_EQUIPPED_ITEM_CLASS, SPELL_FAILED_ERROR, SPELL_FAILED_ITEM_AT_MAX_CHARGES, SPELL_FAILED_ITEM_GONE, SPELL_FAILED_ITEM_NOT_FOUND, SPELL_FAILED_ITEM_NOT_READY, SPELL_FAILED_LOW_CASTLEVEL, SPELL_FAILED_LOWLEVEL, SPELL_FAILED_NEED_MORE_ITEMS, SPELL_FAILED_NO_AMMO, SPELL_FAILED_NO_CHARGES_REMAIN, SPELL_FAILED_NOT_TRADEABLE, SPELL_FAILED_ON_USE_ENCHANT, SPELL_FAILED_REAGENTS, SPELL_FAILED_TOO_MANY_OF_ITEM, SPELL_FAILED_TOTEM_CATEGORY, SPELL_FAILED_TOTEMS, _Spell::SpellCharges, SPELLFAMILY_MAGE, _Spell::SpellId, ItemTemplate::Spells, _Spell::SpellTrigger, sSpellItemEnchantmentStore, ItemTemplate::SubClass, TARGET_UNIT_PET, TRIGGERED_DONT_REPORT_CAST_ERROR, TRIGGERED_IGNORE_EQUIPPED_ITEM_REQUIREMENT, TRIGGERED_IGNORE_POWER_AND_REAGENT_COST, and SpellItemEnchantmentEntry::type.

Referenced by CheckCast().

◆ CheckPetCast()

◆ CheckPower()

◆ CheckRange()

◆ CheckRuneCost()

◆ CheckScriptEffectImplicitTargets()

bool Spell::CheckScriptEffectImplicitTargets ( uint32 effIndex,
uint32 effIndexToCheck )
protected

Definition at line 7897 of file Spell.cpp.

References m_loadedScripts, and m_spellInfo.

Referenced by SelectEffectImplicitTargets().

◆ CheckSrc()

void Spell::CheckSrc ( )
inline

Definition at line 501 of file Spell.h.

References m_caster, and m_targets.

◆ CleanupTargetList()

void Spell::CleanupTargetList ( )

Definition at line 2128 of file Spell.cpp.

References m_delayMoment, m_UniqueGOTargetInfo, m_UniqueItemInfo, and m_UniqueTargetInfo.

Referenced by SelectImplicitAreaTargets(), and Spell().

◆ Delayed()

◆ DelayedChannel()

◆ DoAllEffectOnLaunchTarget()

◆ DoAllEffectOnTarget() [1/3]

◆ DoAllEffectOnTarget() [2/3]

◆ DoAllEffectOnTarget() [3/3]

void Spell::DoAllEffectOnTarget ( TargetInfo * target)
protected
Todo
check how broad this rule should be

Definition at line 2345 of file Spell.cpp.

References SpellNonMeleeDamage::absorb, Creature::AI(), Spell::TargetInfo::alive, AURA_INTERRUPT_FLAG_TALK, Unit::CalculateSpellDamageTaken(), CallScriptAfterHitHandlers(), CallScriptOnHitHandlers(), CanExecuteTriggersOnHit(), Player::CastItemCombatSpell(), createProcExtendMask(), Spell::TargetInfo::crit, Spell::TargetInfo::damage, SpellNonMeleeDamage::damage, Unit::DealDamageMods(), Unit::DealSpellDamage(), DoSpellHitOnUnit(), DoTriggersOnSpellHit(), Spell::TargetInfo::effectMask, ObjectAccessor::FindUnit(), getMSTime(), getState(), Object::GetTypeId(), ObjectAccessor::GetUnit(), HandleEffects(), Unit::HealBySpell(), Unit::IsAIEnabled, Unit::IsAlive(), Unit::IsPvP(), Unit::isSpellCrit(), Unit::IsStandState(), m_attackType, m_caster, m_damage, m_healing, Unit::m_lastSanctuaryTime, m_needComboPoints, m_originalCaster, m_procAttacker, m_procEx, m_procVictim, m_spellAura, m_spellInfo, m_spellSchoolMask, m_targets, m_triggeredByAuraSpell, MAX_SPELL_EFFECTS, Spell::TargetInfo::missCondition, PROC_EX_CRITICAL_HIT, PROC_EX_NORMAL_HIT, PROC_FLAG_DONE_SPELL_MAGIC_DMG_CLASS_NEG, PROC_FLAG_DONE_SPELL_MAGIC_DMG_CLASS_POS, PROC_FLAG_DONE_SPELL_NONE_DMG_CLASS_NEG, PROC_FLAG_DONE_SPELL_NONE_DMG_CLASS_POS, PROC_FLAG_TAKEN_DAMAGE, PROC_FLAG_TAKEN_SPELL_MAGIC_DMG_CLASS_NEG, PROC_FLAG_TAKEN_SPELL_MAGIC_DMG_CLASS_POS, PROC_FLAG_TAKEN_SPELL_NONE_DMG_CLASS_NEG, PROC_FLAG_TAKEN_SPELL_NONE_DMG_CLASS_POS, Unit::ProcDamageAndSpell(), Spell::TargetInfo::processed, Spell::TargetInfo::reflectResult, Spell::TargetInfo::scaleAura, Unit::SendSpellNonMeleeDamageLog(), Unit::SetStandState(), SPELL_ATTR0_CU_AURA_CC, SPELL_ATTR0_CU_PICKPOCKET, SPELL_ATTR0_STOP_ATTACK_TARGET, SPELL_ATTR1_NO_THREAT, SPELL_ATTR3_CANT_TRIGGER_PROC, SPELL_ATTR3_NO_INITIAL_AGGRO, SPELL_DAMAGE_CLASS_MAGIC, SPELL_DAMAGE_CLASS_MELEE, SPELL_DAMAGE_CLASS_NONE, SPELL_DAMAGE_CLASS_RANGED, SPELL_EFFECT_DISPEL, SPELL_EFFECT_HANDLE_HIT_TARGET, SPELL_MISS_DODGE, SPELL_MISS_EVADE, SPELL_MISS_MISS, SPELL_MISS_NONE, SPELL_MISS_PARRY, SPELL_MISS_REFLECT, SPELL_MISS_RESIST, SPELL_STATE_DELAYED, Unit::SpellCriticalHealingBonus(), CreatureAI::SpellHit(), SpellNonMeleeDamage::target, Spell::TargetInfo::targetGUID, Spell::TargetInfo::timeDelay, Object::ToCreature(), Object::ToPlayer(), TYPEID_PLAYER, TYPEID_UNIT, UNIT_STAND_STATE_STAND, and unitTarget.

Referenced by _handle_immediate_phase(), handle_delayed(), and handle_immediate().

◆ DoCreateItem()

◆ DoSpellHitOnUnit()

SpellMissInfo Spell::DoSpellHitOnUnit ( Unit * unit,
uint32 effectMask,
bool scaleAura )
protected
Todo
This is a hack. But we do not know what types of stealth should be interrupted by CC
Todo
this cause soul transfer bugged

Definition at line 2596 of file Spell.cpp.

References ACHIEVEMENT_CRITERIA_TYPE_BE_SPELL_TARGET, ACHIEVEMENT_CRITERIA_TYPE_BE_SPELL_TARGET2, ACHIEVEMENT_CRITERIA_TYPE_CAST_SPELL2, ACHIEVEMENT_TIMED_TYPE_SPELL_CASTER, ACHIEVEMENT_TIMED_TYPE_SPELL_TARGET, Unit::ApplyDiminishingToDuration(), ASSERT, AURA_INTERRUPT_FLAG_HITBYSPELL, SpellEffectInfo::BasePoints, CallScriptBeforeHitHandlers(), CREATURE_FLAG_EXTRA_ALL_DIMINISH, DIMINISHING_NONE, DRTYPE_ALL, DRTYPE_PLAYER, SpellEffectInfo::Effect, SpellInfo::Effects, CreatureTemplate::flags_extra, Unit::GetCharmerOrOwnerGUID(), Unit::GetCharmerOrOwnerPlayerOrPlayerItself(), Unit::GetCombatTimer(), Creature::GetCreatureTemplate(), Unit::GetDiminishing(), GetDiminishingReturnsGroupForSpell(), GetDiminishingReturnsGroupType(), GetDiminishingReturnsLimitDuration(), Unit::getHostileRefManager(), Object::GetTypeId(), HandleEffects(), Object::HasFlag(), Unit::HasUnitState(), Unit::IncrDiminishing(), Unit::IsControlledByPlayer(), Unit::IsImmunedToDamage(), Unit::IsImmunedToSpell(), Unit::IsImmunedToSpellEffect(), Unit::IsInCombat(), m_caster, m_CastItem, m_diminishGroup, m_diminishLevel, m_originalCaster, m_spellAura, m_spellInfo, m_spellValue, m_triggeredByAuraSpell, MAX_SPELL_EFFECTS, PrepareScriptHitHandlers(), Unit::RemoveAurasByType(), Unit::RemoveAurasWithInterruptFlags(), SPELL_ATTR0_CU_AURA_CC, SPELL_ATTR1_NO_THREAT, SPELL_ATTR3_NO_INITIAL_AGGRO, SPELL_ATTR5_HASTE_AFFECT_DURATION, SPELL_AURA_MOD_STEALTH, SPELL_EFFECT_APPLY_AURA, SPELL_EFFECT_HANDLE_HIT_TARGET, SPELL_MISS_EVADE, SPELL_MISS_IMMUNE, SPELL_MISS_NONE, HostileRefManager::threatAssist(), Object::ToCreature(), Object::ToPlayer(), Aura::TryRefreshStackOrCreate(), TYPEID_PLAYER, TYPEID_UNIT, UNIT_FIELD_FLAGS, UNIT_FIELD_MOD_CASTING_SPEED, UNIT_FLAG_NON_ATTACKABLE, UNIT_STATE_ATTACK_PLAYER, and unitTarget.

Referenced by DoAllEffectOnTarget().

◆ DoTriggersOnSpellHit()

void Spell::DoTriggersOnSpellHit ( Unit * unit,
uint32 effMask )
protected
Todo
remove/cleanup this, as this table is not documented and people are doing stupid things with it

Definition at line 2790 of file Spell.cpp.

References CanExecuteTriggersOnHit(), Unit::CastSpell(), Unit::GetAura(), Aura::GetDuration(), m_caster, m_hitTriggerSpells, m_spellInfo, Unit::RemoveAurasDueToSpell(), roll_chance_i(), SF_LOG_DEBUG, SPELL_LINK_HIT, sSpellMgr, TRIGGERED_FULL_MASK, and TRIGGERED_IGNORE_TARGET_CHECK.

Referenced by DoAllEffectOnTarget().

◆ EffectActivateObject()

void Spell::EffectActivateObject ( SpellEffIndex effIndex)

◆ EffectActivateRune()

◆ EffectActivateSpec()

void Spell::EffectActivateSpec ( SpellEffIndex effIndex)

◆ EffectAddComboPoints()

void Spell::EffectAddComboPoints ( SpellEffIndex effIndex)

◆ EffectAddExtraAttacks()

void Spell::EffectAddExtraAttacks ( SpellEffIndex effIndex)

◆ EffectAddFarsight()

◆ EffectApplyAreaAura()

void Spell::EffectApplyAreaAura ( SpellEffIndex effIndex)

◆ EffectApplyAura()

void Spell::EffectApplyAura ( SpellEffIndex effIndex)

◆ EffectApplyGlyph()

◆ EffectBattlePetsUnlock()

◆ EffectBind()

◆ EffectBlock()

void Spell::EffectBlock ( SpellEffIndex effIndex)

◆ EffectCastButtons()

◆ EffectCharge()

◆ EffectChargeDest()

◆ EffectCreateAreaTrigger()

◆ EffectCreateItem()

◆ EffectCreateItem2()

void Spell::EffectCreateItem2 ( SpellEffIndex effIndex)

◆ EffectCreateRandomItem()

void Spell::EffectCreateRandomItem ( SpellEffIndex effIndex)
Todo
ExecuteLogEffectCreateItem(i, m_spellInfo->Effects[i].ItemType);

Definition at line 112 of file SpellEffectsItems.cpp.

References Player::AutoStoreLoot(), effectHandleMode, LootTemplates_Spell, m_spellInfo, SPELL_EFFECT_HANDLE_HIT_TARGET, TYPEID_PLAYER, and unitTarget.

◆ EffectCreateTamedPet()

◆ EffectDamageFromMaxHealthPCT()

void Spell::EffectDamageFromMaxHealthPCT ( SpellEffIndex effIndex)

◆ EffectDestroyAllTotems()

◆ EffectDestroyItem()

◆ EffectDiscoverTaxi()

void Spell::EffectDiscoverTaxi ( SpellEffIndex effIndex)

◆ EffectDisEnchant()

void Spell::EffectDisEnchant ( SpellEffIndex effIndex)

◆ EffectDismissPet()

◆ EffectDispel()

◆ EffectDispelMechanic()

◆ EffectDistract()

◆ EffectDodge()

void Spell::EffectDodge ( SpellEffIndex effIndex)

◆ EffectDualWield()

void Spell::EffectDualWield ( SpellEffIndex effIndex)

◆ EffectDuel()

◆ EffectDummy()

◆ EffectDurabilityDamage()

◆ EffectDurabilityDamagePCT()

void Spell::EffectDurabilityDamagePCT ( SpellEffIndex effIndex)

◆ EffectEnchantHeldItem()

◆ EffectEnchantItemPerm()

◆ EffectEnchantItemPrismatic()

◆ EffectEnchantItemTmp()

◆ EffectEnergize()

◆ EffectEnergizePct()

void Spell::EffectEnergizePct ( SpellEffIndex effIndex)

◆ EffectEnvironmentalDMG()

void Spell::EffectEnvironmentalDMG ( SpellEffIndex effIndex)

◆ EffectFeedPet()

◆ EffectForceCast()

◆ EffectForceDeselect()

◆ EffectGameObjectDamage()

◆ EffectGameObjectRepair()

void Spell::EffectGameObjectRepair ( SpellEffIndex effIndex)

◆ EffectGameObjectSetDestructionState()

void Spell::EffectGameObjectSetDestructionState ( SpellEffIndex effIndex)

◆ EffectGiveCurrency()

void Spell::EffectGiveCurrency ( SpellEffIndex effIndex)

◆ EffectHeal()

◆ EffectHealBattlePetPct()

◆ EffectHealMaxHealth()

void Spell::EffectHealMaxHealth ( SpellEffIndex effIndex)

◆ EffectHealMechanical()

void Spell::EffectHealMechanical ( SpellEffIndex effIndex)

◆ EffectHealPct()

void Spell::EffectHealPct ( SpellEffIndex effIndex)

◆ EffectHealthLeech()

◆ EffectInebriate()

◆ EffectInstaKill()

◆ EffectInterruptCast()

◆ EffectJump()

◆ EffectJumpDest()

◆ EffectKillCredit()

◆ EffectKillCreditPersonal()

void Spell::EffectKillCreditPersonal ( SpellEffIndex effIndex)

◆ EffectKnockBack()

◆ EffectLeap()

◆ EffectLeapBack()

void Spell::EffectLeapBack ( SpellEffIndex effIndex)

◆ EffectLearnPetSpell()

◆ EffectLearnSkill()

void Spell::EffectLearnSkill ( SpellEffIndex effIndex)

◆ EffectLearnSpell()

◆ EffectMilling()

◆ EffectModifyThreatPercent()

void Spell::EffectModifyThreatPercent ( SpellEffIndex effIndex)

◆ EffectNULL()

◆ EffectOpenLock()

◆ EffectParry()

void Spell::EffectParry ( SpellEffIndex effIndex)

◆ EffectPersistentAA()

◆ EffectPickPocket()

◆ EffectPlayMovie()

◆ EffectPlayMusic()

void Spell::EffectPlayMusic ( SpellEffIndex effIndex)

◆ EffectPlaySound()

◆ EffectPowerBurn()

◆ EffectPowerDrain()

◆ EffectProficiency()

◆ EffectProspecting()

◆ EffectPull()

void Spell::EffectPull ( SpellEffIndex effIndex)
Todo
create a proper pull towards distract spell center for distract

Definition at line 219 of file SpellEffectsMovement.cpp.

References EffectNULL().

◆ EffectPullTowards()

◆ EffectQuestClear()

◆ EffectQuestComplete()

◆ EffectQuestFail()

void Spell::EffectQuestFail ( SpellEffIndex effIndex)

◆ EffectQuestStart()

◆ EffectRechargeManaGem()

◆ EffectRedirectThreat()

void Spell::EffectRedirectThreat ( SpellEffIndex effIndex)

◆ EffectRemoveAura()

void Spell::EffectRemoveAura ( SpellEffIndex effIndex)

◆ EffectRemoveTalent()

void Spell::EffectRemoveTalent ( SpellEffIndex effIndex)

◆ EffectRenamePet()

◆ EffectReputation()

◆ EffectResurrect()

◆ EffectResurrectNew()

◆ EffectResurrectWithAura()

◆ EffectSanctuary()

◆ EffectSchoolDMG()

◆ EffectScriptEffect()

void Spell::EffectScriptEffect ( SpellEffIndex effIndex)
Todo
we must implement hunter pet summon at login there (spell 6962)
Todo
a hack, range = 11, should after some time cast, otherwise too far

Definition at line 149 of file SpellEffectsScript.cpp.

References Skyfire::Spells::ProtoTypicalShorteningBlasterSpells::CasterSpellId, CORPSE, damage, destTarget, DoCreateItem(), EFFECT_0, EFFECT_1, effectHandleMode, AuraEffect::GetBase(), Skyfire::Spells::GetBendingShinboneTriggerSpellId(), Skyfire::Spells::GetBigBlizzardBearMountSpellId(), Skyfire::Spells::GetBrewfestSampleSpellId(), Skyfire::Spells::GetBrutallusBurnRangeAuraSpellId(), AuraEffect::GetCasterGUID(), Skyfire::Spells::GetCreateHealthstoneTriggeredSpellId(), Skyfire::Spells::GetDeathboltDirectSpellId(), Skyfire::Spells::GetDeathboltReflectedSpellId(), Skyfire::Spells::GetDeathboltWardAuraSpellId(), Skyfire::Spells::GetDeathKnightInitiateVisualSpellId(), Skyfire::Spells::GetDecimateScriptTriggerSpellId(), Aura::GetDuration(), Aura::GetEffect(), Skyfire::Spells::GetEmblazonRunebladeTriggerSpellId(), Object::GetEntry(), Skyfire::Spells::GetGiftOfTheHarvesterFallbackSpellId(), Skyfire::Spells::GetGoblinWeatherMachineSpellId(), Skyfire::Spells::GetGoldScriptAmount(), Skyfire::Spells::GetGrabCrateParentSpellId(), Skyfire::Spells::GetJudgementFallbackSealTriggerSpellId(), Skyfire::Spells::GetJudgementSealTriggerSpellId(), Skyfire::Spells::GetLightwellChargesAuraSpellId(), Skyfire::Spells::GetLightwellHealSpellId(), Aura::GetMaxDuration(), SpellInfo::GetMaxDuration(), Skyfire::Spells::GetMirrensDrinkingHatItemId(), Skyfire::Spells::GetMugTransformationItemId(), Skyfire::Spells::GetPestilenceBloodPlagueSpellId(), Skyfire::Spells::GetPestilenceFrostFeverSpellId(), Skyfire::Spells::GetPlantWarmaulOgreBannerEventId(), Skyfire::Spells::GetProtoTypicalShorteningBlasterSpells(), Skyfire::Spells::GetScriptEffectStackRemovalAuraSpellId(), Skyfire::Spells::GetShadowFlameScriptRule(), Aura::GetSpellInfo(), AuraEffect::GetSpellInfo(), SpellInfo::GetSpellSpecific(), Skyfire::Spells::GetSummonGhoulsOnScarletCrusadeSpellId(), Skyfire::Spells::GetTeleportingScriptSpellId(), Unit::GetVehicleBase(), Skyfire::Spells::GetWintergraspRpggDropItemCount(), GOLD, Skyfire::Spells::IsScriptDespawnSpell(), itemTarget, m_caster, m_originalCaster, m_spellInfo, m_targets, Skyfire::Spells::ShadowFlameScriptRule::ProtectionAuraSpellId, QUEST_STATUS_COMPLETE, roll_chance_i(), Aura::SetDuration(), Aura::SetMaxDuration(), SF_LOG_DEBUG, SF_LOG_ERROR, SKILL_RIDING, SPELL_AURA_ADD_FLAT_MODIFIER, SPELL_AURA_DUMMY, SPELL_AURA_MOUNTED, SPELL_AURA_PERIODIC_DAMAGE, SPELL_EFFECT_HANDLE_HIT_TARGET, SPELL_SPECIFIC_SEAL, SPELLCATEGORY_JUDGEMENT, SPELLFAMILY_DEATHKNIGHT, SPELLFAMILY_GENERIC, SPELLFAMILY_PALADIN, SPELLFAMILY_WARLOCK, SPELLFAMILY_WARRIOR, SpellInfo::SpellFamilyFlags, SpellInfo::SpellFamilyName, SPELLVALUE_BASE_POINT0, sSpellMgr, sSpellScripts, Skyfire::Spells::ProtoTypicalShorteningBlasterSpells::TargetSpellId, Skyfire::Spells::ShadowFlameScriptRule::TriggerSpellId, TYPEID_PLAYER, TYPEID_UNIT, and unitTarget.

◆ EffectSelfResurrect()

◆ EffectSendEvent()

void Spell::EffectSendEvent ( SpellEffIndex effIndex)

◆ EffectSendTaxi()

void Spell::EffectSendTaxi ( SpellEffIndex effIndex)

◆ EffectSkill()

void Spell::EffectSkill ( SpellEffIndex effIndex)

◆ EffectSkinning()

◆ EffectSkinPlayerCorpse()

void Spell::EffectSkinPlayerCorpse ( SpellEffIndex effIndex)

◆ EffectSpecCount()

void Spell::EffectSpecCount ( SpellEffIndex effIndex)

◆ EffectSpiritHeal()

void Spell::EffectSpiritHeal ( SpellEffIndex effIndex)

Definition at line 172 of file SpellEffectsLifecycle.cpp.

References effectHandleMode, and SPELL_EFFECT_HANDLE_HIT_TARGET.

◆ EffectStealBeneficialBuff()

◆ EffectStuck()

◆ EffectSummonChangeItem()

◆ EffectSummonDeadPet()

◆ EffectSummonObject()

◆ EffectSummonObjectWild()

◆ EffectSummonPet()

◆ EffectSummonPlayer()

◆ EffectSummonRaFFriend()

void Spell::EffectSummonRaFFriend ( SpellEffIndex effIndex)

◆ EffectSummonType()

void Spell::EffectSummonType ( SpellEffIndex effIndex)

Definition at line 183 of file SpellEffectsSummon.cpp.

References SummonPropertiesEntry::Category, MotionMaster::Clear(), damage, destTarget, effectHandleMode, ExecuteLogEffectSummonObject(), SummonPropertiesEntry::Faction, SummonPropertiesEntry::Flags, BattlePetMgr::GetBattlePet(), Player::GetBattlePetMgr(), Creature::GetCreatureTemplate(), BattlePet::GetCurrentHealth(), BattlePetMgr::GetCurrentSummonId(), Unit::GetFollowAngle(), Object::GetGUID(), BattlePet::GetId(), BattlePet::GetLevel(), BattlePet::GetMaxHealth(), Unit::GetMotionMaster(), BattlePet::GetQuality(), Skyfire::Spells::GetSummonCountForProperty(), BattlePet::GetTimestamp(), Skyfire::Spells::GetTotemSummonHealthPct(), SpellInfo::HasAura(), Unit::HasUnitTypeMask(), SpellInfo::Id, SummonPropertiesEntry::Id, Unit::IsTotem(), Unit::IsVehicle(), m_caster, m_originalCaster, m_spellInfo, MOTION_SLOT_ACTIVE, MotionMaster::MoveFollow(), CreatureTemplate::npcflag, PET_FOLLOW_DIST, PLAYER_FIELD_CURRENT_BATTLE_PET_BREED_QUALITY, PLAYER_FIELD_SUMMONED_BATTLE_PET_GUID, Unit::SetCreateHealth(), Unit::SetCreatorGUID(), BattlePetMgr::SetCurrentSummon(), Unit::SetFacingToObject(), Unit::setFaction(), Object::SetFlag(), Unit::SetHealth(), Unit::SetMaxHealth(), Unit::SetOwnerGUID(), Object::SetUInt32Value(), Object::SetUInt64Value(), SF_LOG_ERROR, SPELL_AURA_CONTROL_VEHICLE, SPELL_EFFECT_HANDLE_HIT, SPELLMOD_DURATION, sSpellMgr, sSummonPropertiesStore, SUMMON_CATEGORY_ALLY, SUMMON_CATEGORY_PET, SUMMON_CATEGORY_PUPPET, SUMMON_CATEGORY_UNK, SUMMON_CATEGORY_VEHICLE, SUMMON_CATEGORY_WILD, SUMMON_TYPE_GUARDIAN, SUMMON_TYPE_GUARDIAN2, SUMMON_TYPE_LIGHTWELL, SUMMON_TYPE_MINION, SUMMON_TYPE_MINIPET, SUMMON_TYPE_PET, SUMMON_TYPE_STATUE, SUMMON_TYPE_TOTEM, SUMMON_TYPE_VEHICLE, SUMMON_TYPE_VEHICLE2, SummonGuardian(), TEMPSUMMON_DEAD_DESPAWN, TEMPSUMMON_TIMED_DESPAWN, SummonPropertiesEntry::Type, UNIT_FIELD_BATTLE_PET_COMPANION_GUID, UNIT_FIELD_BATTLE_PET_COMPANION_NAME_TIMESTAMP, UNIT_FIELD_CREATED_BY, UNIT_FIELD_CREATED_BY_SPELL, UNIT_FIELD_FLAGS, UNIT_FIELD_NPC_FLAGS, UNIT_FIELD_WILD_BATTLE_PET_LEVEL, UNIT_FLAG_IMMUNE_TO_NPC, UNIT_FLAG_IMMUNE_TO_PC, UNIT_MASK_MINION, and VEHICLE_SPELL_RIDE_HARDCODED.

◆ EffectTameCreature()

◆ EffectTaunt()

◆ EffectTeleportUnits()

◆ EffectTeleUnitsFaceCaster()

void Spell::EffectTeleUnitsFaceCaster ( SpellEffIndex effIndex)

◆ EffectThreat()

void Spell::EffectThreat ( SpellEffIndex effIndex)

◆ EffectTitanGrip()

void Spell::EffectTitanGrip ( SpellEffIndex effIndex)

◆ EffectTradeSkill()

void Spell::EffectTradeSkill ( SpellEffIndex effIndex)

◆ EffectTransmitted()

◆ EffectTriggerMissileSpell()

◆ EffectTriggerRitualOfSummoning()

void Spell::EffectTriggerRitualOfSummoning ( SpellEffIndex effIndex)

◆ EffectTriggerSpell()

◆ EffectUnlearnSpecialization()

◆ EffectUnlockGuildVaultTab()

void Spell::EffectUnlockGuildVaultTab ( SpellEffIndex effIndex)

◆ EffectUntrainTalents()

void Spell::EffectUntrainTalents ( SpellEffIndex effIndex)

◆ EffectUnused()

◆ EffectWeaponDmg()

◆ ExecuteLogEffectCreateItem()

void Spell::ExecuteLogEffectCreateItem ( uint8 effIndex,
uint32 entry )

Definition at line 4958 of file Spell.cpp.

References ASSERT, m_effectExecuteData, and MAX_SPELL_EFFECTS.

Referenced by EffectCreateItem().

◆ ExecuteLogEffectDestroyItem()

void Spell::ExecuteLogEffectDestroyItem ( uint8 effIndex,
uint32 entry )

Definition at line 4964 of file Spell.cpp.

References ASSERT, m_effectExecuteData, and MAX_SPELL_EFFECTS.

Referenced by EffectFeedPet().

◆ ExecuteLogEffectDurabilityDamage()

void Spell::ExecuteLogEffectDurabilityDamage ( uint8 effIndex,
Unit * victim,
int32 itemId,
int32 slot )

Definition at line 4946 of file Spell.cpp.

References ASSERT, and MAX_SPELL_EFFECTS.

Referenced by EffectDurabilityDamage().

◆ ExecuteLogEffectExtraAttacks()

void Spell::ExecuteLogEffectExtraAttacks ( uint8 effIndex,
Unit * victim,
uint32 attCount )

Definition at line 4908 of file Spell.cpp.

References ASSERT, Object::GetGUID(), m_effectExecuteData, and MAX_SPELL_EFFECTS.

Referenced by EffectAddExtraAttacks().

◆ ExecuteLogEffectInterruptCast()

void Spell::ExecuteLogEffectInterruptCast ( uint8 effIndex,
Unit * victim,
uint32 spellId )

◆ ExecuteLogEffectOpenLock()

void Spell::ExecuteLogEffectOpenLock ( uint8 effIndex,
Object * obj )

Definition at line 4952 of file Spell.cpp.

References ASSERT, Object::GetGUID(), m_effectExecuteData, and MAX_SPELL_EFFECTS.

Referenced by EffectOpenLock().

◆ ExecuteLogEffectResurrect()

void Spell::ExecuteLogEffectResurrect ( uint8 effIndex,
Unit * target )

◆ ExecuteLogEffectSummonObject()

void Spell::ExecuteLogEffectSummonObject ( uint8 effIndex,
WorldObject * obj )

◆ ExecuteLogEffectTakeTargetPower()

void Spell::ExecuteLogEffectTakeTargetPower ( uint8 effIndex,
Unit * target,
uint32 powerType,
uint32 powerTaken,
float gainMultiplier )

Definition at line 4902 of file Spell.cpp.

References ASSERT, Object::GetGUID(), m_effectExecuteData, and MAX_SPELL_EFFECTS.

Referenced by EffectPowerBurn(), and EffectPowerDrain().

◆ ExecuteLogEffectUnsummonObject()

void Spell::ExecuteLogEffectUnsummonObject ( uint8 effIndex,
WorldObject * obj )

Definition at line 4976 of file Spell.cpp.

References ASSERT, Object::GetGUID(), m_effectExecuteData, and MAX_SPELL_EFFECTS.

Referenced by EffectDismissPet().

◆ finish()

◆ FinishTargetProcessing()

void Spell::FinishTargetProcessing ( )
protected

Definition at line 7689 of file Spell.cpp.

References SendLogExecute().

Referenced by handle_delayed(), and handle_immediate().

◆ GetCaster()

Unit * Spell::GetCaster ( ) const
inline

◆ GetCastTime()

int32 Spell::GetCastTime ( ) const
inline

Definition at line 542 of file Spell.h.

References m_casttime.

Referenced by LuaSpell::GetCastTime(), Unit::InterruptSpell(), and Unit::SetCurrentCastedSpell().

◆ GetCurrentContainer()

◆ GetDelayMoment()

uint64 Spell::GetDelayMoment ( ) const
inline

Definition at line 557 of file Spell.h.

References m_delayMoment.

◆ GetDelayStart()

uint64 Spell::GetDelayStart ( ) const
inline

Definition at line 555 of file Spell.h.

References m_delayStart.

◆ GetOriginalCaster()

Unit * Spell::GetOriginalCaster ( ) const
inline

Definition at line 564 of file Spell.h.

References m_originalCaster.

◆ GetPowerCost()

int32 Spell::GetPowerCost ( ) const
inline

Definition at line 566 of file Spell.h.

References m_powerCost.

Referenced by LuaSpell::GetPowerCost().

◆ GetPowerType()

int32 Spell::GetPowerType ( ) const
inline

Definition at line 567 of file Spell.h.

References m_powerType.

◆ GetSearcherTypeMask()

◆ GetSpellInfo()

◆ getState()

uint32 Spell::getState ( ) const
inline

◆ handle_delayed()

◆ handle_immediate()

◆ HandleEffects()

◆ HandleHolyPower()

◆ HandleLaunchPhase()

◆ HandleThreatSpells()

◆ HasGlobalCooldown()

bool Spell::HasGlobalCooldown ( ) const
protected

Definition at line 7968 of file Spell.cpp.

References m_caster, m_spellInfo, and TYPEID_PLAYER.

Referenced by CheckCast().

◆ HaveTargetsForEffect()

bool Spell::HaveTargetsForEffect ( uint8 effect) const

Definition at line 7344 of file Spell.cpp.

References m_UniqueGOTargetInfo, m_UniqueItemInfo, and m_UniqueTargetInfo.

◆ InitExplicitTargets()

◆ IsAutoActionResetSpell()

bool Spell::IsAutoActionResetSpell ( ) const
Todo
changed SPELL_INTERRUPT_FLAG_AUTOATTACK -> SPELL_INTERRUPT_FLAG_INTERRUPT to fix compile - is this check correct at all?

Definition at line 7332 of file Spell.cpp.

References IsTriggered(), m_spellInfo, and SPELL_INTERRUPT_FLAG_INTERRUPT.

Referenced by finish().

◆ IsAutoRepeat()

bool Spell::IsAutoRepeat ( ) const
inline

Definition at line 543 of file Spell.h.

References m_autoRepeat.

Referenced by CheckCast(), GetCurrentContainer(), LuaSpell::IsAutoRepeat(), prepare(), and update().

◆ IsChannelActive()

bool Spell::IsChannelActive ( ) const
inline

Definition at line 548 of file Spell.h.

References m_caster, and UNIT_FIELD_CHANNEL_SPELL.

◆ isDelayableNoMore()

bool Spell::isDelayableNoMore ( )
inlineprotected

Definition at line 604 of file Spell.h.

References m_delayAtDamageCount.

Referenced by Delayed(), and DelayedChannel().

◆ IsDeletable()

bool Spell::IsDeletable ( ) const
inline

Definition at line 551 of file Spell.h.

References m_executedCurrently, and m_referencedFromCurrentSpell.

◆ IsInterruptable()

bool Spell::IsInterruptable ( ) const
inline

Definition at line 553 of file Spell.h.

References m_executedCurrently.

Referenced by Unit::InterruptSpell().

◆ IsNeedSendToClient()

bool Spell::IsNeedSendToClient ( ) const

◆ IsNextMeleeSwingSpell()

bool Spell::IsNextMeleeSwingSpell ( ) const

Definition at line 7327 of file Spell.cpp.

References m_spellInfo, and SPELL_ATTR0_ON_NEXT_SWING.

Referenced by GetCurrentContainer(), and update().

◆ IsTriggered()

bool Spell::IsTriggered ( ) const
inline

◆ IsValidDeadOrAliveTarget()

bool Spell::IsValidDeadOrAliveTarget ( Unit const * target) const
protected

Definition at line 7482 of file Spell.cpp.

References Unit::IsAlive(), and m_spellInfo.

Referenced by UpdateChanneledTargetList().

◆ LoadScripts()

void Spell::LoadScripts ( )
protected

Definition at line 7699 of file Spell.cpp.

References m_loadedScripts, m_spellInfo, SF_LOG_DEBUG, and sScriptMgr.

Referenced by prepare().

◆ operator=()

Spell & Spell::operator= ( Spell const & right)
privatedelete

References Spell().

◆ prepare()

void Spell::prepare ( SpellCastTargets const * targets,
AuraEffect const * triggeredByAura = NULL )

@todoApply this to all casted spells if needed

Definition at line 2939 of file Spell.cpp.

References _triggeredCastFlags, AURA_INTERRUPT_FLAG_CAST, AURA_INTERRUPT_FLAG_SPELL_ATTACK, CalculatePct(), Skyfire::Spells::CalculateSpellPowerCosts(), cast(), SpellPowerEntry::ChannelCostPercentageFloat, CHEAT_CASTTIME, CheckCast(), CURRENT_GENERIC_SPELL, DISABLE_TYPE_SPELL, finish(), AuraEffect::GetBase(), GetCurrentContainer(), AuraEffect::GetSpellInfo(), InitExplicitTargets(), IsAutoRepeat(), DisableMgr::IsDisabledFor(), Aura::IsPassive(), AuraEffect::IsPeriodic(), LoadScripts(), m_auraScaleMask, m_cast_count, m_caster, m_CastItem, m_castItemGUID, m_casttime, m_needComboPoints, m_originalCaster, m_periodicPowerCost, m_powerCost, m_powerType, m_spellInfo, m_spellState, m_spellValue, m_targets, m_triggeredByAuraSpell, SpellPowerEntry::manaCost, SpellPowerEntry::ManaCostPercentageFloat, SpellPowerEntry::manaPerSecond, MAX_POWERS, MAX_SPELL_EFFECTS, Skyfire::Spells::SpellPowerCostCalculationResult::PeriodicPowerCost, POWER_DEMONIC_FURY, POWER_HEALTH, POWER_MANA, Skyfire::Spells::SpellPowerCostCalculationResult::PowerCost, SpellPowerEntry::powerType, prepareDataForTriggerSystem(), GtNPCManaCostScalerEntry::ratio, ReSetTimer(), SendCastResult(), SendChannelUpdate(), SendSpellStart(), Aura::SetDuration(), SF_LOG_DEBUG, SF_LOG_ERROR, sGtNPCManaCostScalerStore, SpellPowerEntry::ShapeShiftSpellID, SPELL_ATTR0_LEVEL_DAMAGE_CALCULATION, SPELL_ATTR1_DRAIN_ALL_POWER, SPELL_AURA_CAST_WHILE_WALKING, SPELL_AURA_MOD_POWER_COST_SCHOOL, SPELL_AURA_MOD_POWER_COST_SCHOOL_PCT, SPELL_CAST_OK, SPELL_EFFECT_APPLY_AURA, SPELL_FAILED_BAD_TARGETS, SPELL_FAILED_MOVING, SPELL_FAILED_SPELL_IN_PROGRESS, SPELL_FAILED_SPELL_UNAVAILABLE, SPELL_INTERRUPT_FLAG_MOVEMENT, Skyfire::Spells::SPELL_POWER_COST_UNKNOWN_POWER_TYPE, Skyfire::Spells::SPELL_POWER_COST_UNSUPPORTED_POWER_TYPE, SPELL_STATE_PREPARING, SpellPowerEntry::spellId, SPELLMOD_COST, sSpellPowerStore, Skyfire::Spells::SpellPowerCostCalculationResult::Status, TARGET_OBJECT_TYPE_UNIT, TRIGGERED_CAST_DIRECTLY, TRIGGERED_IGNORE_AURA_INTERRUPT_FLAGS, TRIGGERED_IGNORE_AURA_SCALING, TRIGGERED_IGNORE_CAST_IN_PROGRESS, TRIGGERED_IGNORE_COMBO_POINTS, TRIGGERED_IGNORE_GCD, TRIGGERED_IGNORE_SET_FACING, TRIGGERED_IGNORE_TARGET_CHECK, TriggerGlobalCooldown(), TYPEID_PLAYER, and TYPEID_UNIT.

Referenced by Unit::_UpdateAutoRepeatSpell(), Player::CastItemUseSpell(), Unit::CastSpell(), EffectDummy(), WorldSession::HandleAcceptTradeOpcode(), WorldSession::HandleCastSpellOpcode(), WorldSession::HandlePetActionHelper(), WorldSession::HandlePetCastSpellOpcode(), and PetAI::UpdateAI().

◆ prepareDataForTriggerSystem()

◆ PrepareScriptHitHandlers()

void Spell::PrepareScriptHitHandlers ( )
protected

◆ PrepareTargetProcessing()

void Spell::PrepareTargetProcessing ( )
protected

Definition at line 7684 of file Spell.cpp.

References CheckEffectExecuteData().

Referenced by handle_delayed(), and handle_immediate().

◆ PrepareTriggersExecutedOnHit()

◆ ReSetTimer()

void Spell::ReSetTimer ( )
inline

Definition at line 545 of file Spell.h.

References m_casttime, and m_timer.

Referenced by prepare().

◆ SearchAreaTargets()

void Spell::SearchAreaTargets ( std::list< WorldObject * > & targets,
float range,
Position const * position,
Unit * referer,
SpellTargetObjectTypes objectType,
SpellTargetCheckTypes selectionType,
ConditionList * condList )

◆ SearchChainTargets()

◆ SearchNearbyTarget()

WorldObject * Spell::SearchNearbyTarget ( float range,
SpellTargetObjectTypes objectType,
SpellTargetCheckTypes selectionType,
ConditionList * condList = NULL )

Definition at line 1921 of file Spell.cpp.

References GetSearcherTypeMask(), m_caster, m_spellInfo, and SearchTargets().

Referenced by SelectImplicitNearbyTargets().

◆ SearchSpellFocus()

GameObject * Spell::SearchSpellFocus ( )

Definition at line 2039 of file Spell.cpp.

References GRID_MAP_TYPE_MASK_GAMEOBJECT, m_caster, m_spellInfo, and SearchTargets().

Referenced by CheckCast().

◆ SearchTargets()

◆ SelectEffectImplicitTargets()

◆ SelectEffectTypeImplicitTargets()

void Spell::SelectEffectTypeImplicitTargets ( uint8 effIndex)

◆ SelectExplicitTargets()

void Spell::SelectExplicitTargets ( )

◆ SelectImplicitAreaTargets()

◆ SelectImplicitCasterDestTargets()

◆ SelectImplicitCasterObjectTargets()

◆ SelectImplicitChainTargets()

◆ SelectImplicitChannelTargets()

◆ SelectImplicitConeTargets()

◆ SelectImplicitDestDestTargets()

◆ SelectImplicitNearbyTargets()

◆ SelectImplicitTargetDestTargets()

◆ SelectImplicitTargetObjectTargets()

void Spell::SelectImplicitTargetObjectTargets ( SpellEffIndex effIndex,
SpellImplicitTargetInfo const & targetType )

◆ SelectImplicitTrajTargets()

void Spell::SelectImplicitTrajTargets ( )
Todo
all calculation should be based on src instead of m_caster

Definition at line 1634 of file Spell.cpp.

References CHECK_DIST, DEBUG_TRAJ, GRID_MAP_TYPE_MASK_ALL, m_caster, m_spellInfo, m_targets, Position::Relocate(), SearchTargets(), SF_LOG_ERROR, tangent(), and unitTarget.

Referenced by SelectImplicitDestDestTargets().

◆ SelectSpellTargets()

◆ SendCastResult() [1/2]

void Spell::SendCastResult ( Player * caster,
SpellInfo const * spellInfo,
uint8 cast_count,
SpellCastResult result,
SpellCustomErrors customError = SPELL_CUSTOM_ERROR_NONE,
Opcodes opcode = SMSG_CAST_FAILED )
static

Definition at line 3874 of file Spell.cpp.

References ByteBuffer::bitwpos(), SpellInfo::Effects, SpellInfo::EquippedItemClass, SpellInfo::EquippedItemSubClassMask, ByteBuffer::FlushBits(), SpellInfo::GetAllEffectsMechanicMask(), Skyfire::Diagnostics::GetRuntimeMetrics(), Player::GetSession(), Player::HasItemCount(), SpellInfo::Id, ItemTemplate::ItemLimitCategory, SpellEffectInfo::ItemType, MAX_SPELL_EFFECTS, MAX_SPELL_REAGENTS, ByteBuffer::PutBits(), SpellInfo::Reagent, SpellInfo::ReagentCount, Skyfire::Diagnostics::RuntimeMetrics::RecordSpellCastFailure(), SpellInfo::RequiresSpellFocus, WorldSession::SendPacket(), sObjectMgr, SPELL_CAST_OK, SPELL_FAILED_CUSTOM_ERROR, SPELL_FAILED_EQUIPPED_ITEM_CLASS, SPELL_FAILED_EQUIPPED_ITEM_CLASS_MAINHAND, SPELL_FAILED_EQUIPPED_ITEM_CLASS_OFFHAND, SPELL_FAILED_FISHING_TOO_LOW, SPELL_FAILED_MIN_SKILL, SPELL_FAILED_NEED_EXOTIC_AMMO, SPELL_FAILED_NEED_MORE_ITEMS, SPELL_FAILED_NOT_READY, SPELL_FAILED_PREVENTED_BY_MECHANIC, SPELL_FAILED_REAGENTS, SPELL_FAILED_REQUIRES_AREA, SPELL_FAILED_REQUIRES_SPELL_FOCUS, SPELL_FAILED_SILENCED, SPELL_FAILED_TOO_MANY_OF_ITEM, SPELL_FAILED_TOTEM_CATEGORY, SPELL_FAILED_TOTEMS, SpellInfo::Totem, SpellInfo::TotemCategory, ByteBuffer::wpos(), and ByteBuffer::WriteBit().

Referenced by cancel(), cast(), spell_putricide_mutation_init::spell_putricide_mutation_init_SpellScript::CheckRequirement(), EffectApplyGlyph(), EffectDuel(), EffectOpenLock(), EffectTaunt(), WorldSession::HandleAcceptTradeOpcode(), WorldSession::HandlePetActionHelper(), spell_putricide_mutated_transformation::spell_putricide_mutated_transformation_SpellScript::HandleSummon(), misc_commandscript::HandleUnstuckCommand(), icecrown_citadel_teleport::OnGossipSelect(), at_frozen_throne_teleport::OnTrigger(), item_only_for_flight::OnUse(), item_petrov_cluster_bombs::OnUse(), prepare(), SelectImplicitAreaTargets(), SelectImplicitCasterDestTargets(), SelectSpellTargets(), SendCastResult(), and SendPetCastResult().

◆ SendCastResult() [2/2]

void Spell::SendCastResult ( SpellCastResult result)

◆ SendChannelStart()

◆ SendChannelUpdate()

◆ SendInterrupted()

void Spell::SendInterrupted ( uint8 result)

◆ SendLogExecute()

◆ SendLoot()

◆ SendPetCastResult()

◆ SendResurrectRequest()

◆ SendSpellCooldown()

◆ SendSpellGo()

◆ SendSpellStart()

◆ SetAutoRepeat()

void Spell::SetAutoRepeat ( bool rep)
inline

Definition at line 544 of file Spell.h.

References m_autoRepeat.

Referenced by LuaSpell::SetAutoRepeat().

◆ SetDelayStart()

void Spell::SetDelayStart ( uint64 m_time)
inline

Definition at line 556 of file Spell.h.

References m_delayStart.

Referenced by cast().

◆ SetExecutedCurrently()

void Spell::SetExecutedCurrently ( bool yes)
inline

Definition at line 554 of file Spell.h.

References m_executedCurrently.

Referenced by cast().

◆ SetReferencedFromCurrent()

void Spell::SetReferencedFromCurrent ( bool yes)
inline

Definition at line 552 of file Spell.h.

References m_referencedFromCurrentSpell.

Referenced by cancel(), Unit::InterruptSpell(), and Unit::SetCurrentCastedSpell().

◆ SetSpellValue()

◆ setState()

void Spell::setState ( uint32 state)
inline

Definition at line 495 of file Spell.h.

References m_spellState.

◆ SummonGuardian()

◆ TakeCastItem()

◆ TakePower()

◆ TakeReagents()

◆ TakeRunePower()

◆ TriggerGlobalCooldown()

void Spell::TriggerGlobalCooldown ( )
protected

◆ update()

◆ UpdateChanneledTargetList()

◆ UpdatePointers()

◆ SpellScript

friend class SpellScript
friend

Definition at line 291 of file Spell.h.

References SpellScript.

Referenced by SpellScript.

◆ Unit::SetCurrentCastedSpell

void Unit::SetCurrentCastedSpell ( Spell * pSpell)
friend

References Spell().

Member Data Documentation

◆ _triggeredCastFlags

◆ damage

◆ destTarget

◆ effectHandleMode

SpellEffectHandleMode Spell::effectHandleMode
protected

Definition at line 631 of file Spell.h.

Referenced by EffectActivateObject(), EffectActivateRune(), EffectActivateSpec(), EffectAddComboPoints(), EffectAddExtraAttacks(), EffectAddFarsight(), EffectApplyAreaAura(), EffectApplyAura(), EffectApplyGlyph(), EffectBattlePetsUnlock(), EffectBind(), EffectBlock(), EffectCastButtons(), EffectCharge(), EffectChargeDest(), EffectCreateAreaTrigger(), EffectCreateItem(), EffectCreateItem2(), EffectCreateRandomItem(), EffectCreateTamedPet(), EffectDamageFromMaxHealthPCT(), EffectDestroyAllTotems(), EffectDestroyItem(), EffectDiscoverTaxi(), EffectDisEnchant(), EffectDismissPet(), EffectDispel(), EffectDispelMechanic(), EffectDistract(), EffectDodge(), EffectDualWield(), EffectDuel(), EffectDummy(), EffectDurabilityDamage(), EffectDurabilityDamagePCT(), EffectEnchantHeldItem(), EffectEnchantItemPerm(), EffectEnchantItemPrismatic(), EffectEnchantItemTmp(), EffectEnergize(), EffectEnergizePct(), EffectEnvironmentalDMG(), EffectFeedPet(), EffectForceCast(), EffectForceDeselect(), EffectGameObjectDamage(), EffectGameObjectRepair(), EffectGameObjectSetDestructionState(), EffectGiveCurrency(), EffectHeal(), EffectHealBattlePetPct(), EffectHealMaxHealth(), EffectHealMechanical(), EffectHealPct(), EffectHealthLeech(), EffectInebriate(), EffectInstaKill(), EffectInterruptCast(), EffectJump(), EffectJumpDest(), EffectKillCredit(), EffectKillCreditPersonal(), EffectKnockBack(), EffectLeap(), EffectLeapBack(), EffectLearnPetSpell(), EffectLearnSkill(), EffectLearnSpell(), EffectMilling(), EffectModifyThreatPercent(), EffectOpenLock(), EffectParry(), EffectPersistentAA(), EffectPickPocket(), EffectPlayMovie(), EffectPlayMusic(), EffectPlaySound(), EffectPowerBurn(), EffectPowerDrain(), EffectProficiency(), EffectProspecting(), EffectPullTowards(), EffectQuestClear(), EffectQuestComplete(), EffectQuestFail(), EffectQuestStart(), EffectRechargeManaGem(), EffectRedirectThreat(), EffectRemoveAura(), EffectRemoveTalent(), EffectRenamePet(), EffectReputation(), EffectResurrect(), EffectResurrectNew(), EffectResurrectWithAura(), EffectSanctuary(), EffectSchoolDMG(), EffectScriptEffect(), EffectSelfResurrect(), EffectSendEvent(), EffectSendTaxi(), EffectSkill(), EffectSkinning(), EffectSkinPlayerCorpse(), EffectSpecCount(), EffectSpiritHeal(), EffectStealBeneficialBuff(), EffectStuck(), EffectSummonChangeItem(), EffectSummonDeadPet(), EffectSummonObject(), EffectSummonObjectWild(), EffectSummonPet(), EffectSummonPlayer(), EffectSummonRaFFriend(), EffectSummonType(), EffectTameCreature(), EffectTaunt(), EffectTeleportUnits(), EffectTeleUnitsFaceCaster(), EffectThreat(), EffectTitanGrip(), EffectTradeSkill(), EffectTransmitted(), EffectTriggerMissileSpell(), EffectTriggerRitualOfSummoning(), EffectTriggerSpell(), EffectUnlearnSpecialization(), EffectUnlockGuildVaultTab(), EffectUntrainTalents(), EffectWeaponDmg(), and HandleEffects().

◆ focusObject

GameObject* Spell::focusObject
protected

◆ gameObjTarget

◆ itemTarget

◆ m_appliedMods

◆ m_applyMultiplierMask

uint8 Spell::m_applyMultiplierMask
protected

◆ m_attackType

◆ m_auraScaleMask

uint8 Spell::m_auraScaleMask
protected

Definition at line 760 of file Spell.h.

Referenced by AddUnitTarget(), prepare(), SelectSpellTargets(), and Spell().

◆ m_autoRepeat

bool Spell::m_autoRepeat
protected

Definition at line 600 of file Spell.h.

Referenced by cancel(), IsAutoRepeat(), SetAutoRepeat(), and Spell().

◆ m_canReflect

bool Spell::m_canReflect
protected

Definition at line 599 of file Spell.h.

Referenced by AddUnitTarget(), and Spell().

◆ m_cast_count

◆ m_caster

Unit* const Spell::m_caster
protected

Definition at line 581 of file Spell.h.

Referenced by _handle_finish_phase(), AddGOTarget(), AddUnitTarget(), CalculateDamage(), cancel(), CancelGlobalCooldown(), CanOpenLock(), cast(), CheckCast(), CheckCasterAuras(), CheckDst(), CheckEffectTarget(), CheckItems(), CheckPetCast(), CheckPower(), CheckRange(), CheckRuneCost(), CheckSrc(), Delayed(), DelayedChannel(), DoAllEffectOnLaunchTarget(), DoAllEffectOnTarget(), DoAllEffectOnTarget(), DoSpellHitOnUnit(), DoTriggersOnSpellHit(), EffectActivateObject(), EffectActivateRune(), EffectAddComboPoints(), EffectAddFarsight(), EffectApplyGlyph(), EffectBind(), EffectBlock(), EffectCastButtons(), EffectCharge(), EffectChargeDest(), EffectCreateAreaTrigger(), EffectCreateItem(), EffectCreateItem2(), EffectDestroyAllTotems(), EffectDisEnchant(), EffectDispel(), EffectDispelMechanic(), EffectDodge(), EffectDuel(), EffectDummy(), EffectEnchantHeldItem(), EffectEnchantItemPerm(), EffectEnchantItemPrismatic(), EffectEnchantItemTmp(), EffectEnergize(), EffectEnergizePct(), EffectEnvironmentalDMG(), EffectFeedPet(), EffectForceCast(), EffectForceDeselect(), EffectGameObjectRepair(), EffectHeal(), EffectHealBattlePetPct(), EffectHealMaxHealth(), EffectHealthLeech(), EffectInstaKill(), EffectJump(), EffectJumpDest(), EffectKnockBack(), EffectLeap(), EffectLeapBack(), EffectLearnSpell(), EffectMilling(), EffectModifyThreatPercent(), EffectOpenLock(), EffectParry(), EffectPersistentAA(), EffectPickPocket(), EffectPlaySound(), EffectPowerBurn(), EffectPowerDrain(), EffectProficiency(), EffectProspecting(), EffectPullTowards(), EffectRechargeManaGem(), EffectRedirectThreat(), EffectResurrect(), EffectResurrectNew(), EffectResurrectWithAura(), EffectSanctuary(), EffectSchoolDMG(), EffectScriptEffect(), EffectSelfResurrect(), EffectSendEvent(), EffectSkinning(), EffectSkinPlayerCorpse(), EffectStealBeneficialBuff(), EffectStuck(), EffectSummonChangeItem(), EffectSummonDeadPet(), EffectSummonObject(), EffectSummonObjectWild(), EffectSummonPet(), EffectSummonPlayer(), EffectSummonRaFFriend(), EffectSummonType(), EffectTameCreature(), EffectTaunt(), EffectTeleportUnits(), EffectTeleUnitsFaceCaster(), EffectThreat(), EffectTitanGrip(), EffectTradeSkill(), EffectTransmitted(), EffectTriggerMissileSpell(), EffectTriggerRitualOfSummoning(), EffectTriggerSpell(), EffectUnlearnSpecialization(), EffectUnlockGuildVaultTab(), EffectUntrainTalents(), EffectWeaponDmg(), ExecuteLogEffectInterruptCast(), finish(), GetCaster(), handle_delayed(), handle_immediate(), HandleHolyPower(), HandleThreatSpells(), HasGlobalCooldown(), InitExplicitTargets(), IsChannelActive(), prepare(), prepareDataForTriggerSystem(), PrepareTriggersExecutedOnHit(), SearchAreaTargets(), SearchChainTargets(), SearchNearbyTarget(), SearchSpellFocus(), SelectEffectImplicitTargets(), SelectEffectTypeImplicitTargets(), SelectExplicitTargets(), SelectImplicitAreaTargets(), SelectImplicitCasterDestTargets(), SelectImplicitCasterObjectTargets(), SelectImplicitChainTargets(), SelectImplicitChannelTargets(), SelectImplicitConeTargets(), SelectImplicitDestDestTargets(), SelectImplicitNearbyTargets(), SelectImplicitTargetDestTargets(), SelectImplicitTrajTargets(), SelectSpellTargets(), SendCastResult(), SendChannelStart(), SendChannelUpdate(), SendInterrupted(), SendLogExecute(), SendLoot(), SendPetCastResult(), SendResurrectRequest(), SendSpellCooldown(), SendSpellGo(), SendSpellStart(), Spell(), SummonGuardian(), TakeCastItem(), TakePower(), TakeReagents(), TakeRunePower(), TriggerGlobalCooldown(), update(), UpdateChanneledTargetList(), UpdatePointers(), and ~Spell().

◆ m_CastItem

◆ m_castItemGUID

uint64 Spell::m_castItemGUID

Definition at line 532 of file Spell.h.

Referenced by CheckItems(), prepare(), Spell(), and UpdatePointers().

◆ m_casttime

int32 Spell::m_casttime
protected

Definition at line 598 of file Spell.h.

Referenced by CheckRange(), Delayed(), GetCastTime(), prepare(), ReSetTimer(), SendSpellStart(), Spell(), and update().

◆ m_channelTargetEffectMask

uint8 Spell::m_channelTargetEffectMask
protected

Definition at line 672 of file Spell.h.

Referenced by SelectSpellTargets(), SendSpellGo(), Spell(), and UpdateChanneledTargetList().

◆ m_comboPointGain

int8 Spell::m_comboPointGain

Definition at line 536 of file Spell.h.

Referenced by _handle_finish_phase(), and Spell().

◆ m_customError

SpellCustomErrors Spell::m_customError

Definition at line 537 of file Spell.h.

Referenced by CheckCast(), SendCastResult(), and Spell().

◆ m_damage

◆ m_damageMultipliers

float Spell::m_damageMultipliers[3]
protected

Definition at line 623 of file Spell.h.

Referenced by DoAllEffectOnLaunchTarget(), and SelectImplicitChainTargets().

◆ m_delayAtDamageCount

uint8 Spell::m_delayAtDamageCount
protected

Definition at line 603 of file Spell.h.

Referenced by isDelayableNoMore(), and Spell().

◆ m_delayMoment

uint64 Spell::m_delayMoment
protected

◆ m_delayStart

uint64 Spell::m_delayStart
protected

Definition at line 614 of file Spell.h.

Referenced by GetDelayStart(), SetDelayStart(), and Spell().

◆ m_destTargets

SpellDestination Spell::m_destTargets[MAX_SPELL_EFFECTS]
protected

Definition at line 690 of file Spell.h.

Referenced by AddDestTarget(), HandleEffects(), Spell(), and UpdatePointers().

◆ m_diminishGroup

DiminishingGroup Spell::m_diminishGroup
protected

Definition at line 637 of file Spell.h.

Referenced by _handle_immediate_phase(), and DoSpellHitOnUnit().

◆ m_diminishLevel

DiminishingLevels Spell::m_diminishLevel
protected

Definition at line 636 of file Spell.h.

Referenced by _handle_immediate_phase(), and DoSpellHitOnUnit().

◆ m_effectExecuteData

◆ m_executedCurrently

bool Spell::m_executedCurrently
protected

Definition at line 620 of file Spell.h.

Referenced by IsDeletable(), IsInterruptable(), SetExecutedCurrently(), and Spell().

◆ m_glyphIndex

◆ m_healing

int32 Spell::m_healing
protected

◆ m_hitTriggerSpells

HitTriggerSpellList Spell::m_hitTriggerSpells
protected

Definition at line 740 of file Spell.h.

Referenced by DoTriggersOnSpellHit(), and PrepareTriggersExecutedOnHit().

◆ m_immediateHandled

bool Spell::m_immediateHandled
protected

Definition at line 616 of file Spell.h.

Referenced by cast(), and handle_delayed().

◆ m_loadedScripts

◆ m_needComboPoints

bool Spell::m_needComboPoints
protected

Definition at line 621 of file Spell.h.

Referenced by _handle_finish_phase(), CheckCast(), DoAllEffectOnTarget(), prepare(), and Spell().

◆ m_originalCaster

◆ m_originalCasterGUID

◆ m_periodicPowerCost

int32 Spell::m_periodicPowerCost
protected

Definition at line 596 of file Spell.h.

Referenced by prepare(), Spell(), and update().

◆ m_periodicPowerTimer

int32 Spell::m_periodicPowerTimer
protected

Definition at line 595 of file Spell.h.

Referenced by Spell(), and update().

◆ m_powerCost

int32 Spell::m_powerCost
protected

◆ m_powerType

int32 Spell::m_powerType
protected

◆ m_preGeneratedPath

PathGenerator Spell::m_preGeneratedPath
protected

Definition at line 761 of file Spell.h.

Referenced by CheckCast(), EffectCharge(), and Spell().

◆ m_procAttacker

uint32 Spell::m_procAttacker
protected

◆ m_procEx

uint32 Spell::m_procEx
protected

◆ m_procVictim

uint32 Spell::m_procVictim
protected

Definition at line 650 of file Spell.h.

Referenced by DoAllEffectOnTarget(), and prepareDataForTriggerSystem().

◆ m_referencedFromCurrentSpell

bool Spell::m_referencedFromCurrentSpell
protected

Definition at line 619 of file Spell.h.

Referenced by IsDeletable(), SetReferencedFromCurrent(), Spell(), and ~Spell().

◆ m_researchData

◆ m_runesState

uint8 Spell::m_runesState
protected

Definition at line 601 of file Spell.h.

Referenced by EffectActivateRune(), SendSpellGo(), Spell(), and TakeRunePower().

◆ m_selfContainer

Spell** Spell::m_selfContainer
protected

Definition at line 589 of file Spell.h.

Referenced by cancel(), CheckCast(), Unit::SetCurrentCastedSpell(), Spell(), and ~Spell().

◆ m_skipCheck

bool Spell::m_skipCheck
protected

Definition at line 759 of file Spell.h.

Referenced by AddUnitTarget(), and Spell().

◆ m_spellAura

◆ m_spellInfo

SpellInfo const* const Spell::m_spellInfo

Definition at line 530 of file Spell.h.

Referenced by _handle_immediate_phase(), AddGOTarget(), AddItemTarget(), AddUnitTarget(), CalculateDamage(), CalculateJumpSpeeds(), CallScriptEffectHandlers(), CallScriptObjectAreaTargetSelectHandlers(), CallScriptObjectTargetSelectHandlers(), CanAutoCast(), cancel(), CancelGlobalCooldown(), CanExecuteTriggersOnHit(), CanOpenLock(), cast(), CheckArenaAndRatedBattlegroundCastRules(), CheckCast(), CheckCasterAuras(), CheckEffectTarget(), CheckItems(), CheckPetCast(), CheckPower(), CheckRange(), CheckRuneCost(), CheckScriptEffectImplicitTargets(), Delayed(), DelayedChannel(), DoAllEffectOnLaunchTarget(), DoAllEffectOnTarget(), DoCreateItem(), DoSpellHitOnUnit(), DoTriggersOnSpellHit(), EffectActivateRune(), EffectAddFarsight(), EffectApplyGlyph(), EffectBind(), EffectCastButtons(), EffectCharge(), EffectCreateAreaTrigger(), EffectCreateItem(), EffectCreateItem2(), EffectCreateRandomItem(), EffectCreateTamedPet(), EffectDestroyItem(), EffectDiscoverTaxi(), EffectDisEnchant(), EffectDispel(), EffectDispelMechanic(), EffectDuel(), EffectDummy(), EffectDurabilityDamage(), EffectDurabilityDamagePCT(), EffectEnchantHeldItem(), EffectEnchantItemPerm(), EffectEnchantItemPrismatic(), EffectEnchantItemTmp(), EffectEnergize(), EffectEnergizePct(), EffectEnvironmentalDMG(), EffectFeedPet(), EffectForceCast(), EffectGameObjectSetDestructionState(), EffectGiveCurrency(), EffectHeal(), EffectHealBattlePetPct(), EffectHealMechanical(), EffectHealPct(), EffectHealthLeech(), EffectInstaKill(), EffectInterruptCast(), EffectJumpDest(), EffectKillCredit(), EffectKillCreditPersonal(), EffectKnockBack(), EffectLeapBack(), EffectLearnPetSpell(), EffectLearnSkill(), EffectLearnSpell(), EffectNULL(), EffectOpenLock(), EffectPersistentAA(), EffectPlayMusic(), EffectPlaySound(), EffectPowerBurn(), EffectPowerDrain(), EffectProficiency(), EffectPullTowards(), EffectQuestClear(), EffectQuestComplete(), EffectQuestFail(), EffectQuestStart(), EffectRechargeManaGem(), EffectRemoveAura(), EffectReputation(), EffectResurrect(), EffectResurrectNew(), EffectSanctuary(), EffectSchoolDMG(), EffectScriptEffect(), EffectSelfResurrect(), EffectSendEvent(), EffectSendTaxi(), EffectStealBeneficialBuff(), EffectSummonChangeItem(), EffectSummonObject(), EffectSummonObjectWild(), EffectSummonPet(), EffectSummonRaFFriend(), EffectSummonType(), EffectTameCreature(), EffectTeleportUnits(), EffectTeleUnitsFaceCaster(), EffectTransmitted(), EffectTriggerMissileSpell(), EffectTriggerRitualOfSummoning(), EffectTriggerSpell(), EffectUnlearnSpecialization(), EffectUnlockGuildVaultTab(), EffectUnused(), EffectWeaponDmg(), ExecuteLogEffectInterruptCast(), finish(), GetCurrentContainer(), LuaSpell::GetId(), GetSearcherTypeMask(), GetSpellInfo(), handle_immediate(), HandleEffects(), HandleHolyPower(), HandleLaunchPhase(), HandleThreatSpells(), WorldSession::HandleUpdateMissileTrajectory(), HasGlobalCooldown(), InitExplicitTargets(), IsAutoActionResetSpell(), IsNeedSendToClient(), IsNextMeleeSwingSpell(), IsValidDeadOrAliveTarget(), LoadScripts(), prepare(), prepareDataForTriggerSystem(), PrepareTriggersExecutedOnHit(), Player::RestoreSpellMods(), SearchAreaTargets(), SearchChainTargets(), SearchNearbyTarget(), SearchSpellFocus(), SelectEffectImplicitTargets(), SelectEffectTypeImplicitTargets(), SelectExplicitTargets(), SelectImplicitAreaTargets(), SelectImplicitCasterDestTargets(), SelectImplicitChainTargets(), SelectImplicitChannelTargets(), SelectImplicitConeTargets(), SelectImplicitDestDestTargets(), SelectImplicitNearbyTargets(), SelectImplicitTargetDestTargets(), SelectImplicitTrajTargets(), SelectSpellTargets(), SendCastResult(), SendChannelStart(), SendInterrupted(), SendLogExecute(), SendPetCastResult(), SendResurrectRequest(), SendSpellCooldown(), SendSpellGo(), SendSpellStart(), SetSpellValue(), Spell(), SummonGuardian(), TakePower(), TakeReagents(), TakeRunePower(), TriggerGlobalCooldown(), update(), PetAI::UpdateAI(), UpdateChanneledTargetList(), Player::UpdatePotionCooldown(), and ~Spell().

◆ m_spellSchoolMask

SpellSchoolMask Spell::m_spellSchoolMask
protected

Definition at line 592 of file Spell.h.

Referenced by DoAllEffectOnLaunchTarget(), DoAllEffectOnTarget(), and Spell().

◆ m_spellState

uint32 Spell::m_spellState
protected

Definition at line 749 of file Spell.h.

Referenced by cancel(), cast(), finish(), getState(), handle_immediate(), prepare(), setState(), Spell(), and update().

◆ m_spellValue

◆ m_targets

◆ m_timer

int32 Spell::m_timer
protected

Definition at line 750 of file Spell.h.

Referenced by Delayed(), DelayedChannel(), ReSetTimer(), SendChannelStart(), Spell(), and update().

◆ m_triggeredByAuraSpell

SpellInfo const* Spell::m_triggeredByAuraSpell
protected

◆ m_UniqueGOTargetInfo

std::list<GOTargetInfo> Spell::m_UniqueGOTargetInfo
protected

◆ m_UniqueItemInfo

std::list<ItemTargetInfo> Spell::m_UniqueItemInfo
protected

◆ m_UniqueTargetInfo

◆ unitTarget

Unit* Spell::unitTarget
protected

Definition at line 626 of file Spell.h.

Referenced by CheckCast(), DoAllEffectOnTarget(), DoCreateItem(), DoSpellHitOnUnit(), EffectActivateSpec(), EffectAddComboPoints(), EffectAddExtraAttacks(), EffectApplyAreaAura(), EffectApplyAura(), EffectBind(), EffectCharge(), EffectCreateItem2(), EffectCreateRandomItem(), EffectCreateTamedPet(), EffectDamageFromMaxHealthPCT(), EffectDestroyItem(), EffectDiscoverTaxi(), EffectDismissPet(), EffectDispel(), EffectDispelMechanic(), EffectDistract(), EffectDualWield(), EffectDuel(), EffectDummy(), EffectDurabilityDamage(), EffectDurabilityDamagePCT(), EffectEnchantHeldItem(), EffectEnchantItemPerm(), EffectEnergize(), EffectEnergizePct(), EffectEnvironmentalDMG(), EffectForceCast(), EffectGiveCurrency(), EffectHeal(), EffectHealMaxHealth(), EffectHealMechanical(), EffectHealPct(), EffectHealthLeech(), EffectInebriate(), EffectInstaKill(), EffectInterruptCast(), EffectJump(), EffectKillCredit(), EffectKillCreditPersonal(), EffectKnockBack(), EffectLeap(), EffectLeapBack(), EffectLearnPetSpell(), EffectLearnSkill(), EffectLearnSpell(), EffectModifyThreatPercent(), EffectPickPocket(), EffectPlayMovie(), EffectPlayMusic(), EffectPlaySound(), EffectPowerBurn(), EffectPowerDrain(), EffectPullTowards(), EffectQuestClear(), EffectQuestComplete(), EffectQuestFail(), EffectQuestStart(), EffectRechargeManaGem(), EffectRedirectThreat(), EffectRemoveAura(), EffectRenamePet(), EffectReputation(), EffectResurrect(), EffectResurrectNew(), EffectResurrectWithAura(), EffectSanctuary(), EffectSchoolDMG(), EffectScriptEffect(), EffectSendEvent(), EffectSendTaxi(), EffectSkinning(), EffectSkinPlayerCorpse(), EffectSpecCount(), EffectStealBeneficialBuff(), EffectSummonPlayer(), EffectSummonRaFFriend(), EffectTameCreature(), EffectTaunt(), EffectTeleportUnits(), EffectTeleUnitsFaceCaster(), EffectThreat(), EffectTriggerMissileSpell(), EffectTriggerSpell(), EffectUnlearnSpecialization(), EffectUntrainTalents(), EffectWeaponDmg(), HandleEffects(), SearchChainTargets(), SelectEffectTypeImplicitTargets(), SelectImplicitAreaTargets(), SelectImplicitChainTargets(), SelectImplicitConeTargets(), SelectImplicitNearbyTargets(), SelectImplicitTrajTargets(), and Spell().


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