SpellAttr fixes and more #120

This commit is contained in:
Elmsroth 2020-11-16 21:32:25 +00:00 committed by Antz
parent a8b44fe925
commit adbc5e16ff
19 changed files with 153 additions and 130 deletions

View File

@ -128,7 +128,7 @@ bool ChatHandler::HandleMmapPathCommand(char* args)
for (uint32 i = 0; i < pointPath.size(); ++i) for (uint32 i = 0; i < pointPath.size(); ++i)
{ {
player->SummonCreature(VISUAL_WAYPOINT, pointPath[i].x, pointPath[i].y, pointPath[i].z, 0, TEMPSUMMON_TIMED_DESPAWN, 9000); player->SummonCreature(VISUAL_WAYPOINT, pointPath[i].x, pointPath[i].y, pointPath[i].z, 0, TEMPSPAWN_TIMED_DESPAWN, 9000);
} }
if (followPath) if (followPath)
@ -385,7 +385,7 @@ bool ChatHandler::HandleMmapTestHeight(char* args)
float gx, gy, gz; float gx, gy, gz;
unit->GetPosition(gx, gy, gz); unit->GetPosition(gx, gy, gz);
Creature* summoned = unit->SummonCreature(VISUAL_WAYPOINT, gx, gy, gz + 0.5f, 0, TEMPSUMMON_TIMED_DESPAWN, 20000); Creature* summoned = unit->SummonCreature(VISUAL_WAYPOINT, gx, gy, gz + 0.5f, 0, TEMPSPAWN_TIMED_DESPAWN, 20000);
summoned->CastSpell(summoned, 8599, false); summoned->CastSpell(summoned, 8599, false);
uint32 tries = 1; uint32 tries = 1;
uint32 successes = 0; uint32 successes = 0;
@ -395,7 +395,7 @@ bool ChatHandler::HandleMmapTestHeight(char* args)
unit->GetPosition(gx, gy, gz); unit->GetPosition(gx, gy, gz);
if (unit->GetMap()->GetReachableRandomPosition(unit, gx, gy, gz, radius)) if (unit->GetMap()->GetReachableRandomPosition(unit, gx, gy, gz, radius))
{ {
unit->SummonCreature(VISUAL_WAYPOINT, gx, gy, gz, 0, TEMPSUMMON_TIMED_DESPAWN, 15000); unit->SummonCreature(VISUAL_WAYPOINT, gx, gy, gz, 0, TEMPSPAWN_TIMED_DESPAWN, 15000);
++successes; ++successes;
if (successes >= 100) if (successes >= 100)
{ {

View File

@ -55,7 +55,7 @@ inline Creature* Helper_CreateWaypointFor(Creature* wpOwner, WaypointPathOrigin
wpCreature->SetActiveObjectState(true); wpCreature->SetActiveObjectState(true);
wpCreature->Summon(TEMPSUMMON_TIMED_DESPAWN, 5 * MINUTE * IN_MILLISECONDS); // Also initializes the AI and MMGen wpCreature->Summon(TEMPSPAWN_TIMED_DESPAWN, 5 * MINUTE * IN_MILLISECONDS); // Also initializes the AI and MMGen
return wpCreature; return wpCreature;
} }

View File

@ -794,11 +794,11 @@ void CreatureEventAI::ProcessAction(CreatureEventAI_Action const& action, uint32
if (action.summon.duration) if (action.summon.duration)
{ {
pCreature = m_creature->SummonCreature(action.summon.creatureId, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_OOC_OR_DEAD_DESPAWN, action.summon.duration); pCreature = m_creature->SummonCreature(action.summon.creatureId, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSPAWN_TIMED_OOC_OR_DEAD_DESPAWN, action.summon.duration);
} }
else else
{ {
pCreature = m_creature->SummonCreature(action.summon.creatureId, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_OOC_DESPAWN, 0); pCreature = m_creature->SummonCreature(action.summon.creatureId, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSPAWN_TIMED_OOC_DESPAWN, 0);
} }
if (!pCreature) if (!pCreature)
@ -1025,11 +1025,11 @@ void CreatureEventAI::ProcessAction(CreatureEventAI_Action const& action, uint32
Creature* pCreature = NULL; Creature* pCreature = NULL;
if (i->second.SpawnTimeSecs) if (i->second.SpawnTimeSecs)
{ {
pCreature = m_creature->SummonCreature(action.summon_id.creatureId, i->second.position_x, i->second.position_y, i->second.position_z, i->second.orientation, TEMPSUMMON_TIMED_OOC_OR_DEAD_DESPAWN, i->second.SpawnTimeSecs); pCreature = m_creature->SummonCreature(action.summon_id.creatureId, i->second.position_x, i->second.position_y, i->second.position_z, i->second.orientation, TEMPSPAWN_TIMED_OOC_OR_DEAD_DESPAWN, i->second.SpawnTimeSecs);
} }
else else
{ {
pCreature = m_creature->SummonCreature(action.summon_id.creatureId, i->second.position_x, i->second.position_y, i->second.position_z, i->second.orientation, TEMPSUMMON_TIMED_OOC_DESPAWN, 0); pCreature = m_creature->SummonCreature(action.summon_id.creatureId, i->second.position_x, i->second.position_y, i->second.position_z, i->second.orientation, TEMPSPAWN_TIMED_OOC_DESPAWN, 0);
} }
if (!pCreature) if (!pCreature)
@ -1232,11 +1232,11 @@ void CreatureEventAI::ProcessAction(CreatureEventAI_Action const& action, uint32
if ((*i).second.SpawnTimeSecs) if ((*i).second.SpawnTimeSecs)
{ {
pCreature = m_creature->SummonCreature(action.summon_unique.creatureId, (*i).second.position_x, (*i).second.position_y, (*i).second.position_z, (*i).second.orientation, TEMPSUMMON_TIMED_OOC_OR_DEAD_DESPAWN, (*i).second.SpawnTimeSecs); pCreature = m_creature->SummonCreature(action.summon_unique.creatureId, (*i).second.position_x, (*i).second.position_y, (*i).second.position_z, (*i).second.orientation, TEMPSPAWN_TIMED_OOC_OR_DEAD_DESPAWN, (*i).second.SpawnTimeSecs);
} }
else else
{ {
pCreature = m_creature->SummonCreature(action.summon_unique.creatureId, (*i).second.position_x, (*i).second.position_y, (*i).second.position_z, (*i).second.orientation, TEMPSUMMON_TIMED_OOC_DESPAWN, 0); pCreature = m_creature->SummonCreature(action.summon_unique.creatureId, (*i).second.position_x, (*i).second.position_y, (*i).second.position_z, (*i).second.orientation, TEMPSPAWN_TIMED_OOC_DESPAWN, 0);
} }
if (!pCreature) if (!pCreature)

View File

@ -1582,7 +1582,7 @@ void WorldObject::AddObjectToRemoveList()
GetMap()->AddObjectToRemoveList(this); GetMap()->AddObjectToRemoveList(this);
} }
Creature* WorldObject::SummonCreature(uint32 id, float x, float y, float z, float ang, TempSummonType spwtype, uint32 despwtime, bool asActiveObject, bool setRun) Creature* WorldObject::SummonCreature(uint32 id, float x, float y, float z, float ang, TempSpawnType spwtype, uint32 despwtime, bool asActiveObject, bool setRun)
{ {
CreatureInfo const* cinfo = ObjectMgr::GetCreatureTemplate(id); CreatureInfo const* cinfo = ObjectMgr::GetCreatureTemplate(id);
if (!cinfo) if (!cinfo)

View File

@ -50,18 +50,18 @@
#define MAX_STEALTH_DETECT_RANGE 45.0f #define MAX_STEALTH_DETECT_RANGE 45.0f
enum TempSummonType enum TempSpawnType
{ {
TEMPSUMMON_MANUAL_DESPAWN = 0, // despawns when UnSummon() is called TEMPSPAWN_MANUAL_DESPAWN = 0, // despawns when UnSummon() is called
TEMPSUMMON_DEAD_DESPAWN = 1, // despawns when the creature disappears TEMPSPAWN_DEAD_DESPAWN = 1, // despawns when the creature disappears
TEMPSUMMON_CORPSE_DESPAWN = 2, // despawns instantly after death TEMPSPAWN_CORPSE_DESPAWN = 2, // despawns instantly after death
TEMPSUMMON_CORPSE_TIMED_DESPAWN = 3, // despawns after a specified time after death (or when the creature disappears) TEMPSPAWN_CORPSE_TIMED_DESPAWN = 3, // despawns after a specified time after death (or when the creature disappears)
TEMPSUMMON_TIMED_DESPAWN = 4, // despawns after a specified time TEMPSPAWN_TIMED_DESPAWN = 4, // despawns after a specified time
TEMPSUMMON_TIMED_OOC_DESPAWN = 5, // despawns after a specified time after the creature is out of combat TEMPSPAWN_TIMED_OOC_DESPAWN = 5, // despawns after a specified time after the creature is out of combat
TEMPSUMMON_TIMED_OR_DEAD_DESPAWN = 6, // despawns after a specified time OR when the creature disappears TEMPSPAWN_TIMED_OR_DEAD_DESPAWN = 6, // despawns after a specified time OR when the creature disappears
TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN = 7, // despawns after a specified time OR when the creature dies TEMPSPAWN_TIMED_OR_CORPSE_DESPAWN = 7, // despawns after a specified time OR when the creature dies
TEMPSUMMON_TIMED_OOC_OR_DEAD_DESPAWN = 8, // despawns after a specified time (OOC) OR when the creature disappears TEMPSPAWN_TIMED_OOC_OR_DEAD_DESPAWN = 8, // despawns after a specified time (OOC) OR when the creature disappears
TEMPSUMMON_TIMED_OOC_OR_CORPSE_DESPAWN = 9, // despawns after a specified time (OOC) OR when the creature dies TEMPSPAWN_TIMED_OOC_OR_CORPSE_DESPAWN = 9, // despawns after a specified time (OOC) OR when the creature dies
}; };
class WorldPacket; class WorldPacket;
@ -671,7 +671,7 @@ class WorldObject : public Object
void RemoveFromClientUpdateList() override; void RemoveFromClientUpdateList() override;
void BuildUpdateData(UpdateDataMapType&) override; void BuildUpdateData(UpdateDataMapType&) override;
Creature* SummonCreature(uint32 id, float x, float y, float z, float ang, TempSummonType spwtype, uint32 despwtime, bool asActiveObject = false, bool setRun = false); Creature* SummonCreature(uint32 id, float x, float y, float z, float ang, TempSpawnType spwtype, uint32 despwtime, bool asActiveObject = false, bool setRun = false);
GameObject* SummonGameObject(uint32 id, float x, float y, float z, float angle, uint32 despwtime); GameObject* SummonGameObject(uint32 id, float x, float y, float z, float angle, uint32 despwtime);
bool IsActiveObject() const { return m_isActiveObject || m_viewPoint.hasViewers(); } bool IsActiveObject() const { return m_isActiveObject || m_viewPoint.hasViewers(); }

View File

@ -7501,7 +7501,7 @@ bool PlayerCondition::Meets(Player const* player, Map const* map, WorldObject co
{ {
Unit::SpellAuraHolderMap const& auras = player->GetSpellAuraHolderMap(); Unit::SpellAuraHolderMap const& auras = player->GetSpellAuraHolderMap();
for (Unit::SpellAuraHolderMap::const_iterator itr = auras.begin(); itr != auras.end(); ++itr) for (Unit::SpellAuraHolderMap::const_iterator itr = auras.begin(); itr != auras.end(); ++itr)
if ((itr->second->GetSpellProto()->HasAttribute(SPELL_ATTR_CASTABLE_WHILE_MOUNTED) || itr->second->GetSpellProto()->HasAttribute(SPELL_ATTR_UNK4)) && itr->second->GetSpellProto()->SpellVisual == 3580) if ((itr->second->GetSpellProto()->HasAttribute(SPELL_ATTR_CASTABLE_WHILE_MOUNTED) || itr->second->GetSpellProto()->HasAttribute(SPELL_ATTR_ABILITY)) && itr->second->GetSpellProto()->SpellVisual == 3580)
{ {
return true; return true;
} }

View File

@ -156,7 +156,7 @@ uint32 GetSpellCastTime(SpellEntry const* spellInfo, Spell const* spell)
modOwner->ApplySpellMod(spellInfo->Id, SPELLMOD_CASTING_TIME, castTime, spell); modOwner->ApplySpellMod(spellInfo->Id, SPELLMOD_CASTING_TIME, castTime, spell);
} }
if (!spellInfo->HasAttribute(SPELL_ATTR_UNK4) && !spellInfo->HasAttribute(SPELL_ATTR_TRADESPELL)) if (!spellInfo->HasAttribute(SPELL_ATTR_ABILITY) && !spellInfo->HasAttribute(SPELL_ATTR_TRADESPELL))
{ {
castTime = int32(castTime * spell->GetCaster()->GetFloatValue(UNIT_MOD_CAST_SPEED)); castTime = int32(castTime * spell->GetCaster()->GetFloatValue(UNIT_MOD_CAST_SPEED));
} }
@ -974,7 +974,7 @@ bool IsPositiveEffect(SpellEntry const* spellproto, SpellEffectIndex effIndex)
return false; return false;
} }
// but not this if this first effect (don't found better check) // but not this if this first effect (don't found better check)
if (spellproto->HasAttribute(SPELL_ATTR_UNK26) && effIndex == EFFECT_INDEX_0) if (spellproto->HasAttribute(SPELL_ATTR_AURA_IS_DEBUFF) && effIndex == EFFECT_INDEX_0)
{ {
return false; return false;
} }
@ -1046,7 +1046,7 @@ bool IsPositiveEffect(SpellEntry const* spellproto, SpellEffectIndex effIndex)
} }
// AttributesEx check // AttributesEx check
if (spellproto->HasAttribute(SPELL_ATTR_EX_NEGATIVE)) if (spellproto->HasAttribute(SPELL_ATTR_EX_CANT_BE_REFLECTED))
{ {
return false; return false;
} }

View File

@ -566,7 +566,7 @@ inline bool IsChanneledSpell(SpellEntry const* spellInfo)
inline bool IsNeedCastSpellAtFormApply(SpellEntry const* spellInfo, ShapeshiftForm form) inline bool IsNeedCastSpellAtFormApply(SpellEntry const* spellInfo, ShapeshiftForm form)
{ {
if ((!spellInfo->HasAttribute(SPELL_ATTR_PASSIVE) && !spellInfo->HasAttribute(SPELL_ATTR_HIDE_SPELL)) || !form) if ((!spellInfo->HasAttribute(SPELL_ATTR_PASSIVE) && !spellInfo->HasAttribute(SPELL_ATTR_HIDDEN_CLIENTSIDE)) || !form)
{ {
return false; return false;
} }

View File

@ -27,7 +27,7 @@
#include "CreatureAI.h" #include "CreatureAI.h"
TemporarySummon::TemporarySummon(ObjectGuid summoner) : TemporarySummon::TemporarySummon(ObjectGuid summoner) :
Creature(CREATURE_SUBTYPE_TEMPORARY_SUMMON), m_type(TEMPSUMMON_TIMED_OOC_OR_CORPSE_DESPAWN), m_timer(0), m_lifetime(0), m_summoner(summoner) Creature(CREATURE_SUBTYPE_TEMPORARY_SUMMON), m_type(TEMPSPAWN_TIMED_OOC_OR_CORPSE_DESPAWN), m_timer(0), m_lifetime(0), m_summoner(summoner)
{ {
} }
@ -35,9 +35,9 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
{ {
switch (m_type) switch (m_type)
{ {
case TEMPSUMMON_MANUAL_DESPAWN: case TEMPSPAWN_MANUAL_DESPAWN:
break; break;
case TEMPSUMMON_TIMED_DESPAWN: case TEMPSPAWN_TIMED_DESPAWN:
{ {
if (m_timer <= update_diff) if (m_timer <= update_diff)
{ {
@ -48,7 +48,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
m_timer -= update_diff; m_timer -= update_diff;
break; break;
} }
case TEMPSUMMON_TIMED_OOC_DESPAWN: case TEMPSPAWN_TIMED_OOC_DESPAWN:
{ {
if (!IsInCombat()) if (!IsInCombat())
{ {
@ -68,7 +68,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
break; break;
} }
case TEMPSUMMON_CORPSE_TIMED_DESPAWN: case TEMPSPAWN_CORPSE_TIMED_DESPAWN:
{ {
if (IsCorpse()) if (IsCorpse())
{ {
@ -87,7 +87,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
} }
break; break;
} }
case TEMPSUMMON_CORPSE_DESPAWN: case TEMPSPAWN_CORPSE_DESPAWN:
{ {
// if m_deathState is DEAD, CORPSE was skipped // if m_deathState is DEAD, CORPSE was skipped
if (IsDead()) if (IsDead())
@ -98,7 +98,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
break; break;
} }
case TEMPSUMMON_DEAD_DESPAWN: case TEMPSPAWN_DEAD_DESPAWN:
{ {
if (IsDespawned()) if (IsDespawned())
{ {
@ -107,7 +107,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
} }
break; break;
} }
case TEMPSUMMON_TIMED_OOC_OR_CORPSE_DESPAWN: case TEMPSPAWN_TIMED_OOC_OR_CORPSE_DESPAWN:
{ {
// if m_deathState is DEAD, CORPSE was skipped // if m_deathState is DEAD, CORPSE was skipped
if (IsDead()) if (IsDead())
@ -134,7 +134,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
} }
break; break;
} }
case TEMPSUMMON_TIMED_OOC_OR_DEAD_DESPAWN: case TEMPSPAWN_TIMED_OOC_OR_DEAD_DESPAWN:
{ {
// if m_deathState is DEAD, CORPSE was skipped // if m_deathState is DEAD, CORPSE was skipped
if (IsDespawned()) if (IsDespawned())
@ -161,7 +161,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
} }
break; break;
} }
case TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN: case TEMPSPAWN_TIMED_OR_CORPSE_DESPAWN:
{ {
// if m_deathState is DEAD, CORPSE was skipped // if m_deathState is DEAD, CORPSE was skipped
if (IsDead()) if (IsDead())
@ -177,7 +177,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
m_timer -= update_diff; m_timer -= update_diff;
break; break;
} }
case TEMPSUMMON_TIMED_OR_DEAD_DESPAWN: case TEMPSPAWN_TIMED_OR_DEAD_DESPAWN:
{ {
// if m_deathState is DEAD, CORPSE was skipped // if m_deathState is DEAD, CORPSE was skipped
if (IsDespawned()) if (IsDespawned())
@ -214,7 +214,7 @@ void TemporarySummon::Update(uint32 update_diff, uint32 diff)
Creature::Update(update_diff, diff); Creature::Update(update_diff, diff);
} }
void TemporarySummon::Summon(TempSummonType type, uint32 lifetime) void TemporarySummon::Summon(TempSpawnType type, uint32 lifetime)
{ {
m_type = type; m_type = type;
m_timer = lifetime; m_timer = lifetime;

View File

@ -35,14 +35,14 @@ class TemporarySummon : public Creature
virtual ~TemporarySummon() {}; virtual ~TemporarySummon() {};
void Update(uint32 update_diff, uint32 time) override; void Update(uint32 update_diff, uint32 time) override;
void Summon(TempSummonType type, uint32 lifetime); void Summon(TempSpawnType type, uint32 lifetime);
void UnSummon(); void UnSummon();
void SaveToDB() override; void SaveToDB() override;
virtual void RemoveFromWorld() override; virtual void RemoveFromWorld() override;
ObjectGuid const& GetSummonerGuid() const { return m_summoner ; } ObjectGuid const& GetSummonerGuid() const { return m_summoner ; }
Unit* GetSummoner() const { return sObjectAccessor.GetUnit(*this, m_summoner); } Unit* GetSummoner() const { return sObjectAccessor.GetUnit(*this, m_summoner); }
private: private:
TempSummonType m_type; TempSpawnType m_type;
uint32 m_timer; uint32 m_timer;
uint32 m_lifetime; uint32 m_lifetime;
ObjectGuid m_summoner; ObjectGuid m_summoner;

View File

@ -2457,7 +2457,7 @@ void Unit::CalculateAbsorbResistBlock(Unit* pCaster, SpellNonMeleeDamage* damage
damageInfo->damage -= damageInfo->blocked; damageInfo->damage -= damageInfo->blocked;
} }
CalculateDamageAbsorbAndResist(pCaster, GetSpellSchoolMask(spellProto), SPELL_DIRECT_DAMAGE, damageInfo->damage, &damageInfo->absorb, &damageInfo->resist, !spellProto->HasAttribute(SPELL_ATTR_EX2_CANT_REFLECTED)); CalculateDamageAbsorbAndResist(pCaster, GetSpellSchoolMask(spellProto), SPELL_DIRECT_DAMAGE, damageInfo->damage, &damageInfo->absorb, &damageInfo->resist, !spellProto->HasAttribute(SPELL_ATTR_EX2_IGNORE_LOS));
damageInfo->damage -= damageInfo->absorb + damageInfo->resist; damageInfo->damage -= damageInfo->absorb + damageInfo->resist;
} }

View File

@ -1773,6 +1773,29 @@ class Unit : public WorldObject
return (creatureType >= 1) ? (1 << (creatureType - 1)) : 0; return (creatureType >= 1) ? (1 << (creatureType - 1)) : 0;
} }
bool isVendor() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_VENDOR); }
bool isTrainer() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_TRAINER); }
bool isQuestGiver() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER); }
bool isGossip() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP); }
bool isTaxi() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_FLIGHTMASTER); }
bool isGuildMaster() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_PETITIONER); }
bool isBattleMaster() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_BATTLEMASTER); }
bool isBanker() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_BANKER); }
bool isInnkeeper() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_INNKEEPER); }
bool isSpiritHealer() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_SPIRITHEALER); }
bool isSpiritGuide() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_SPIRITGUIDE); }
bool isTabardDesigner()const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_TABARDDESIGNER); }
bool isArmorer() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_REPAIR); }
bool isServiceProvider() const
{
return HasFlag(UNIT_NPC_FLAGS,
UNIT_NPC_FLAG_VENDOR | UNIT_NPC_FLAG_TRAINER | UNIT_NPC_FLAG_FLIGHTMASTER |
UNIT_NPC_FLAG_PETITIONER | UNIT_NPC_FLAG_BATTLEMASTER | UNIT_NPC_FLAG_BANKER |
UNIT_NPC_FLAG_INNKEEPER | UNIT_NPC_FLAG_SPIRITHEALER |
UNIT_NPC_FLAG_SPIRITGUIDE | UNIT_NPC_FLAG_TABARDDESIGNER | UNIT_NPC_FLAG_AUCTIONEER);
}
bool isSpiritService() const { return HasFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_SPIRITHEALER | UNIT_NPC_FLAG_SPIRITGUIDE); }
/** /**
* Gets the current stand state for this Unit as described by UnitStandStateType. * Gets the current stand state for this Unit as described by UnitStandStateType.
* @return The current stand state * @return The current stand state

View File

@ -320,7 +320,7 @@ void LoadDBCStores(const std::string& dataPath)
} }
SpellEntry const* spellInfo = sSpellStore.LookupEntry(skillLine->spellId); SpellEntry const* spellInfo = sSpellStore.LookupEntry(skillLine->spellId);
if (spellInfo && (spellInfo->Attributes & (SPELL_ATTR_UNK4 | SPELL_ATTR_PASSIVE | SPELL_ATTR_HIDE_SPELL | SPELL_ATTR_UNK8)) == (SPELL_ATTR_UNK4 | SPELL_ATTR_PASSIVE | SPELL_ATTR_HIDE_SPELL | SPELL_ATTR_UNK8)) if (spellInfo && (spellInfo->Attributes & (SPELL_ATTR_ABILITY | SPELL_ATTR_PASSIVE | SPELL_ATTR_HIDDEN_CLIENTSIDE | SPELL_ATTR_HIDE_IN_COMBAT_LOG)) == (SPELL_ATTR_ABILITY | SPELL_ATTR_PASSIVE | SPELL_ATTR_HIDDEN_CLIENTSIDE | SPELL_ATTR_HIDE_IN_COMBAT_LOG))
{ {
for (unsigned int i = 1; i < sCreatureFamilyStore.GetNumRows(); ++i) for (unsigned int i = 1; i < sCreatureFamilyStore.GetNumRows(); ++i)
{ {

View File

@ -281,12 +281,12 @@ enum SpellAttributes
SPELL_ATTR_RANGED = 0x00000002, // 1 All ranged abilites have this flag SPELL_ATTR_RANGED = 0x00000002, // 1 All ranged abilites have this flag
SPELL_ATTR_ON_NEXT_SWING_1 = 0x00000004, // 2 on next swing SPELL_ATTR_ON_NEXT_SWING_1 = 0x00000004, // 2 on next swing
SPELL_ATTR_UNK3 = 0x00000008, // 3 not set in 2.4.2 SPELL_ATTR_UNK3 = 0x00000008, // 3 not set in 2.4.2
SPELL_ATTR_UNK4 = 0x00000010, // 4 isAbility SPELL_ATTR_ABILITY = 0x00000010, // 4 Displays ability instead of spell clientside
SPELL_ATTR_TRADESPELL = 0x00000020, // 5 trade spells, will be added by client to a sublist of profession spell SPELL_ATTR_TRADESPELL = 0x00000020, // 5 trade spells, will be added by client to a sublist of profession spell
SPELL_ATTR_PASSIVE = 0x00000040, // 6 Passive spell SPELL_ATTR_PASSIVE = 0x00000040, // 6 Passive spell
SPELL_ATTR_HIDE_SPELL = 0x00000080, // 7 Shows no spell icon SPELL_ATTR_HIDDEN_CLIENTSIDE = 0x00000080, // 7 Spells with this attribute are not visible in spellbook or aura bar TODO: check usage
SPELL_ATTR_UNK8 = 0x00000100, // 8 hide created item in tooltip (for effect=24) SPELL_ATTR_HIDE_IN_COMBAT_LOG = 0x00000100, // 8 hide created item in tooltip (for effect=24) TODO: implement it
SPELL_ATTR_UNK9 = 0x00000200, // 9 SPELL_ATTR_TARGET_MAINHAND_ITEM = 0x00000200, // 9 Client automatically selects item from mainhand slot as a cast target TODO: Implement
SPELL_ATTR_ON_NEXT_SWING_2 = 0x00000400, // 10 on next swing 2 SPELL_ATTR_ON_NEXT_SWING_2 = 0x00000400, // 10 on next swing 2
SPELL_ATTR_UNK11 = 0x00000800, // 11 SPELL_ATTR_UNK11 = 0x00000800, // 11
SPELL_ATTR_DAYTIME_ONLY = 0x00001000, // 12 only useable at daytime, not set in 2.4.2 SPELL_ATTR_DAYTIME_ONLY = 0x00001000, // 12 only useable at daytime, not set in 2.4.2
@ -295,15 +295,15 @@ enum SpellAttributes
SPELL_ATTR_OUTDOORS_ONLY = 0x00008000, // 15 Only useable outdoors. SPELL_ATTR_OUTDOORS_ONLY = 0x00008000, // 15 Only useable outdoors.
SPELL_ATTR_NOT_SHAPESHIFT = 0x00010000, // 16 Not while shapeshifted SPELL_ATTR_NOT_SHAPESHIFT = 0x00010000, // 16 Not while shapeshifted
SPELL_ATTR_ONLY_STEALTHED = 0x00020000, // 17 Must be in stealth SPELL_ATTR_ONLY_STEALTHED = 0x00020000, // 17 Must be in stealth
SPELL_ATTR_UNK18 = 0x00040000, // 18 SPELL_ATTR_DONT_AFFECT_SHEATH_STATE = 0x00040000, // 18 client won't hide unit weapons in sheath on cast/channel TODO: Implement
SPELL_ATTR_LEVEL_DAMAGE_CALCULATION = 0x00080000, // 19 spelldamage depends on caster level SPELL_ATTR_LEVEL_DAMAGE_CALCULATION = 0x00080000, // 19 spelldamage depends on caster level
SPELL_ATTR_STOP_ATTACK_TARGET = 0x00100000, // 20 Stop attack after use this spell (and not begin attack if use) SPELL_ATTR_STOP_ATTACK_TARGET = 0x00100000, // 20 Stop attack after use this spell (and not begin attack if use)
SPELL_ATTR_IMPOSSIBLE_DODGE_PARRY_BLOCK = 0x00200000, // 21 Can not be dodged/parried/blocked SPELL_ATTR_IMPOSSIBLE_DODGE_PARRY_BLOCK = 0x00200000, // 21 Can not be dodged/parried/blocked
SPELL_ATTR_SET_TRACKING_TARGET = 0x00400000, // 22 SetTrackingTarget SPELL_ATTR_SET_TRACKING_TARGET = 0x00400000, // 22 SetTrackingTarget
SPELL_ATTR_UNK23 = 0x00800000, // 23 castable while dead? SPELL_ATTR_CASTABLE_WHILE_DEAD = 0x00800000, // 23 castable while dead - TODO: Implement
SPELL_ATTR_CASTABLE_WHILE_MOUNTED = 0x01000000, // 24 castable while mounted SPELL_ATTR_CASTABLE_WHILE_MOUNTED = 0x01000000, // 24 castable while mounted
SPELL_ATTR_DISABLED_WHILE_ACTIVE = 0x02000000, // 25 Activate and start cooldown after aura fade or remove summoned creature or go SPELL_ATTR_DISABLED_WHILE_ACTIVE = 0x02000000, // 25 Activate and start cooldown after aura fade or remove summoned creature or go
SPELL_ATTR_UNK26 = 0x04000000, // 26 SPELL_ATTR_AURA_IS_DEBUFF = 0x04000000, // 26
SPELL_ATTR_CASTABLE_WHILE_SITTING = 0x08000000, // 27 castable while sitting SPELL_ATTR_CASTABLE_WHILE_SITTING = 0x08000000, // 27 castable while sitting
SPELL_ATTR_CANT_USED_IN_COMBAT = 0x10000000, // 28 Can not be used in combat SPELL_ATTR_CANT_USED_IN_COMBAT = 0x10000000, // 28 Can not be used in combat
SPELL_ATTR_UNAFFECTED_BY_INVULNERABILITY = 0x20000000, // 29 unaffected by invulnerability (hmm possible not...) SPELL_ATTR_UNAFFECTED_BY_INVULNERABILITY = 0x20000000, // 29 unaffected by invulnerability (hmm possible not...)
@ -316,21 +316,21 @@ enum SpellAttributesEx
SPELL_ATTR_EX_UNK0 = 0x00000001, // 0 SPELL_ATTR_EX_UNK0 = 0x00000001, // 0
SPELL_ATTR_EX_DRAIN_ALL_POWER = 0x00000002, // 1 use all power (Only paladin Lay of Hands and Bunyanize) SPELL_ATTR_EX_DRAIN_ALL_POWER = 0x00000002, // 1 use all power (Only paladin Lay of Hands and Bunyanize)
SPELL_ATTR_EX_CHANNELED_1 = 0x00000004, // 2 channeled 1 SPELL_ATTR_EX_CHANNELED_1 = 0x00000004, // 2 channeled 1
SPELL_ATTR_EX_UNK3 = 0x00000008, // 3 SPELL_ATTR_EX_CANT_BE_REDIRECTED = 0x00000008, // 3
SPELL_ATTR_EX_UNK4 = 0x00000010, // 4 SPELL_ATTR_EX_UNK4 = 0x00000010, // 4
SPELL_ATTR_EX_NOT_BREAK_STEALTH = 0x00000020, // 5 Not break stealth SPELL_ATTR_EX_NOT_BREAK_STEALTH = 0x00000020, // 5 Not break stealth
SPELL_ATTR_EX_CHANNELED_2 = 0x00000040, // 6 channeled 2 SPELL_ATTR_EX_CHANNELED_2 = 0x00000040, // 6 channeled 2
SPELL_ATTR_EX_NEGATIVE = 0x00000080, // 7 SPELL_ATTR_EX_CANT_BE_REFLECTED = 0x00000080, // 7
SPELL_ATTR_EX_NOT_IN_COMBAT_TARGET = 0x00000100, // 8 Spell req target not to be in combat state SPELL_ATTR_EX_NOT_IN_COMBAT_TARGET = 0x00000100, // 8 Spell req target not to be in combat state
SPELL_ATTR_EX_UNK9 = 0x00000200, // 9 SPELL_ATTR_EX_FACING_TARGET = 0x00000200, // 9 TODO: CONFIRM!
SPELL_ATTR_EX_NO_THREAT = 0x00000400, // 10 no generates threat on cast 100% SPELL_ATTR_EX_NO_THREAT = 0x00000400, // 10 no generates threat on cast 100%
SPELL_ATTR_EX_UNK11 = 0x00000800, // 11 SPELL_ATTR_EX_UNK11 = 0x00000800, // 11
SPELL_ATTR_EX_UNK12 = 0x00001000, // 12 SPELL_ATTR_EX_IS_PICKPOCKET = 0x00001000, // 12
SPELL_ATTR_EX_FARSIGHT = 0x00002000, // 13 related to farsight SPELL_ATTR_EX_FARSIGHT = 0x00002000, // 13 related to farsight
SPELL_ATTR_EX_UNK14 = 0x00004000, // 14 SPELL_ATTR_EX_CHANNEL_TRACK_TARGET = 0x00004000, // 14
SPELL_ATTR_EX_DISPEL_AURAS_ON_IMMUNITY = 0x00008000, // 15 remove auras on immunity SPELL_ATTR_EX_DISPEL_AURAS_ON_IMMUNITY = 0x00008000, // 15 remove auras on immunity
SPELL_ATTR_EX_UNAFFECTED_BY_SCHOOL_IMMUNE = 0x00010000, // 16 unaffected by school immunity SPELL_ATTR_EX_UNAFFECTED_BY_SCHOOL_IMMUNE = 0x00010000, // 16 unaffected by school immunity
SPELL_ATTR_EX_UNK17 = 0x00020000, // 17 for auras SPELL_AURA_TRACK_CREATURES, SPELL_AURA_TRACK_RESOURCES and SPELL_AURA_TRACK_STEALTHED select non-stacking tracking spells SPELL_ATTR_EX_UNAUTOCASTABLE_BY_CHARMED = 0x00020000, // 17 TODO: Investigate more: SPELL_ATTR_EX_PLAYER_CANT_CAST_CHARMED, likely related to MC ,for auras SPELL_AURA_TRACK_CREATURES, SPELL_AURA_TRACK_RESOURCES and SPELL_AURA_TRACK_STEALTHED select non-stacking tracking spells
SPELL_ATTR_EX_UNK18 = 0x00040000, // 18 SPELL_ATTR_EX_UNK18 = 0x00040000, // 18
SPELL_ATTR_EX_CANT_TARGET_SELF = 0x00080000, // 19 spells that exclude the caster SPELL_ATTR_EX_CANT_TARGET_SELF = 0x00080000, // 19 spells that exclude the caster
SPELL_ATTR_EX_REQ_TARGET_COMBO_POINTS = 0x00100000, // 20 Req combo points on target SPELL_ATTR_EX_REQ_TARGET_COMBO_POINTS = 0x00100000, // 20 Req combo points on target
@ -340,22 +340,22 @@ enum SpellAttributesEx
SPELL_ATTR_EX_UNK24 = 0x01000000, // 24 Req fishing pole?? SPELL_ATTR_EX_UNK24 = 0x01000000, // 24 Req fishing pole??
SPELL_ATTR_EX_UNK25 = 0x02000000, // 25 not set in 2.4.2 SPELL_ATTR_EX_UNK25 = 0x02000000, // 25 not set in 2.4.2
SPELL_ATTR_EX_UNK26 = 0x04000000, // 26 SPELL_ATTR_EX_UNK26 = 0x04000000, // 26
SPELL_ATTR_EX_UNK27 = 0x08000000, // 27 SPELL_ATTR_EX_REFUND_POWER = 0x08000000, // 27 All these spells refund power on parry or deflect
SPELL_ATTR_EX_UNK28 = 0x10000000, // 28 SPELL_ATTR_EX_DONT_DISPLAY_IN_AURA_BAR = 0x10000000, // 28
SPELL_ATTR_EX_UNK29 = 0x20000000, // 29 SPELL_ATTR_EX_CHANNEL_DISPLAY_SPELL_NAME = 0x20000000, // 29
SPELL_ATTR_EX_UNK30 = 0x40000000, // 30 overpower SPELL_ATTR_EX_ENABLE_AT_DODGE = 0x40000000, // 30 overpower
SPELL_ATTR_EX_UNK31 = 0x80000000, // 31 SPELL_ATTR_EX_UNK31 = 0x80000000, // 31
}; };
enum SpellAttributesEx2 enum SpellAttributesEx2
{ {
SPELL_ATTR_EX2_UNK0 = 0x00000001, // 0 SPELL_ATTR_EX2_CAN_TARGET_DEAD = 0x00000001, // 0 can target dead unit or corpse
SPELL_ATTR_EX2_UNK1 = 0x00000002, // 1 SPELL_ATTR_EX2_UNK1 = 0x00000002, // 1
SPELL_ATTR_EX2_CANT_REFLECTED = 0x00000004, // 2 ? used for detect can or not spell reflected // do not need LOS (e.g. 18220 since 3.3.3) SPELL_ATTR_EX2_IGNORE_LOS = 0x00000004, // 2 ? used for detect can or not spell reflected // do not need LOS (e.g. 18220 since 3.3.3)
SPELL_ATTR_EX2_UNK3 = 0x00000008, // 3 auto targeting? (e.g. fishing skill enhancement items since 3.3.3) SPELL_ATTR_EX2_UNK3 = 0x00000008, // 3 auto targeting? (e.g. fishing skill enhancement items since 3.3.3)
SPELL_ATTR_EX2_UNK4 = 0x00000010, // 4 SPELL_ATTR_EX2_DISPLAY_IN_STANCE_BAR = 0x00000010, // 4
SPELL_ATTR_EX2_AUTOREPEAT_FLAG = 0x00000020, // 5 SPELL_ATTR_EX2_AUTOREPEAT_FLAG = 0x00000020, // 5
SPELL_ATTR_EX2_UNK6 = 0x00000040, // 6 only usable on tabbed by yourself SPELL_ATTR_EX2_CANT_TARGET_TAPPED = 0x00000040, // 6 only usable on tabbed by yourself
SPELL_ATTR_EX2_UNK7 = 0x00000080, // 7 SPELL_ATTR_EX2_UNK7 = 0x00000080, // 7
SPELL_ATTR_EX2_UNK8 = 0x00000100, // 8 not set in 2.4.2 SPELL_ATTR_EX2_UNK8 = 0x00000100, // 8 not set in 2.4.2
SPELL_ATTR_EX2_UNK9 = 0x00000200, // 9 SPELL_ATTR_EX2_UNK9 = 0x00000200, // 9
@ -365,43 +365,43 @@ enum SpellAttributesEx2
SPELL_ATTR_EX2_UNK13 = 0x00002000, // 13 SPELL_ATTR_EX2_UNK13 = 0x00002000, // 13
SPELL_ATTR_EX2_UNK14 = 0x00004000, // 14 SPELL_ATTR_EX2_UNK14 = 0x00004000, // 14
SPELL_ATTR_EX2_UNK15 = 0x00008000, // 15 not set in 2.4.2 SPELL_ATTR_EX2_UNK15 = 0x00008000, // 15 not set in 2.4.2
SPELL_ATTR_EX2_UNK16 = 0x00010000, // 16 SPELL_ATTR_EX2_TAME_BEAST = 0x00010000, // 16
SPELL_ATTR_EX2_NOT_RESET_AUTO_ACTIONS = 0x00020000, // 17 suspend weapon timer instead of resetting it, (?Hunters Shot and Stings only have this flag?) SPELL_ATTR_EX2_NOT_RESET_AUTO_ACTIONS = 0x00020000, // 17 suspend weapon timer instead of resetting it, (?Hunters Shot and Stings only have this flag?)
SPELL_ATTR_EX2_UNK18 = 0x00040000, // 18 Only Revive pet - possible req dead pet SPELL_ATTR_EX2_REQ_DEAD_PET = 0x00040000, // 18 Only Revive pet - possible req dead pet
SPELL_ATTR_EX2_NOT_NEED_SHAPESHIFT = 0x00080000, // 19 does not necessary need shapeshift (pre-3.x not have passive spells with this attribute) SPELL_ATTR_EX2_NOT_NEED_SHAPESHIFT = 0x00080000, // 19 does not necessary need shapeshift (pre-3.x not have passive spells with this attribute)
SPELL_ATTR_EX2_UNK20 = 0x00100000, // 20 SPELL_ATTR_EX2_FACING_TARGETS_BACK = 0x00100000, // 20 TODO: CONFIRM!
SPELL_ATTR_EX2_DAMAGE_REDUCED_SHIELD = 0x00200000, // 21 for ice blocks, pala immunity buffs, priest absorb shields, but used also for other spells -> not sure! SPELL_ATTR_EX2_DAMAGE_REDUCED_SHIELD = 0x00200000, // 21 for ice blocks, pala immunity buffs, priest absorb shields, but used also for other spells -> not sure!
SPELL_ATTR_EX2_UNK22 = 0x00400000, // 22 SPELL_ATTR_EX2_UNK22 = 0x00400000, // 22
SPELL_ATTR_EX2_UNK23 = 0x00800000, // 23 Only mage Arcane Concentration have this flag SPELL_ATTR_EX2_IS_ARCANE_CONCENTRATION = 0x00800000, // 23 Only mage Arcane Concentration have this flag
SPELL_ATTR_EX2_UNK24 = 0x01000000, // 24 SPELL_ATTR_EX2_UNK24 = 0x01000000, // 24
SPELL_ATTR_EX2_UNK25 = 0x02000000, // 25 SPELL_ATTR_EX2_UNK25 = 0x02000000, // 25
SPELL_ATTR_EX2_UNK26 = 0x04000000, // 26 unaffected by school immunity SPELL_ATTR_EX2_UNK26 = 0x04000000, // 26 unaffected by school immunity
SPELL_ATTR_EX2_UNK27 = 0x08000000, // 27 SPELL_ATTR_EX2_UNK27 = 0x08000000, // 27
SPELL_ATTR_EX2_UNK28 = 0x10000000, // 28 no breaks stealth if it fails?? SPELL_ATTR_EX2_UNK28 = 0x10000000, // 28 no breaks stealth if it fails??
SPELL_ATTR_EX2_CANT_CRIT = 0x20000000, // 29 Spell can't crit SPELL_ATTR_EX2_CANT_CRIT = 0x20000000, // 29 Spell can't crit
SPELL_ATTR_EX2_UNK30 = 0x40000000, // 30 SPELL_ATTR_EX2_TRIGGERED_CAN_TRIGGER_PROC = 0x40000000, // 30
SPELL_ATTR_EX2_FOOD_BUFF = 0x80000000, // 31 Food or Drink Buff (like Well Fed) SPELL_ATTR_EX2_FOOD_BUFF = 0x80000000, // 31 Food or Drink Buff (like Well Fed)
}; };
enum SpellAttributesEx3 enum SpellAttributesEx3
{ {
SPELL_ATTR_EX3_UNK0 = 0x00000001, // 0 SPELL_ATTR_EX3_OUT_OF_COMBAT_ATTACK = 0x00000001, // 0 Spell landed counts as hostile action against enemy even if it doesn't trigger combat state, propagates PvP flags
SPELL_ATTR_EX3_UNK1 = 0x00000002, // 1 SPELL_ATTR_EX3_UNK1 = 0x00000002, // 1
SPELL_ATTR_EX3_UNK2 = 0x00000004, // 2 SPELL_ATTR_EX3_UNK2 = 0x00000004, // 2
SPELL_ATTR_EX3_UNK3 = 0x00000008, // 3 SPELL_ATTR_EX3_BLOCKABLE_SPELL = 0x00000008, // 3
SPELL_ATTR_EX3_UNK4 = 0x00000010, // 4 Druid Rebirth only this spell have this flag SPELL_ATTR_EX3_IGNORE_RESURRECTION_TIMER = 0x00000010, // 4 Druid Rebirth only this spell have this flag
SPELL_ATTR_EX3_UNK5 = 0x00000020, // 5 SPELL_ATTR_EX3_UNK5 = 0x00000020, // 5
SPELL_ATTR_EX3_UNK6 = 0x00000040, // 6 SPELL_ATTR_EX3_UNK6 = 0x00000040, // 6
SPELL_ATTR_EX3_UNK7 = 0x00000080, // 7 create a separate (de)buff stack for each caster SPELL_ATTR_EX3_STACK_FOR_DIFF_CASTERS = 0x00000080, // 7 create a separate (de)buff stack for each caster
SPELL_ATTR_EX3_TARGET_ONLY_PLAYER = 0x00000100, // 8 Can target only player SPELL_ATTR_EX3_TARGET_ONLY_PLAYER = 0x00000100, // 8 Can target only player
SPELL_ATTR_EX3_UNK9 = 0x00000200, // 9 SPELL_ATTR_EX3_TRIGGERED_CAN_TRIGGER_SPECIAL = 0x00000200, // 9 Can only proc auras with SPELL_ATTR_EX3_CAN_PROC_FROM_TRIGGERED_SPECIAL
SPELL_ATTR_EX3_MAIN_HAND = 0x00000400, // 10 Main hand weapon required SPELL_ATTR_EX3_MAIN_HAND = 0x00000400, // 10 Main hand weapon required
SPELL_ATTR_EX3_BATTLEGROUND = 0x00000800, // 11 Can casted only on battleground SPELL_ATTR_EX3_BATTLEGROUND = 0x00000800, // 11 Can casted only on battleground
SPELL_ATTR_EX3_CAST_ON_DEAD = 0x00001000, // 12 target is a dead player (not every spell has this flag) SPELL_ATTR_EX3_CAST_ON_DEAD = 0x00001000, // 12 target is a dead player (not every spell has this flag)
SPELL_ATTR_EX3_UNK13 = 0x00002000, // 13 SPELL_ATTR_EX3_DONT_DISPLAY_CHANNEL_BAR = 0x00002000, // 13
SPELL_ATTR_EX3_UNK14 = 0x00004000, // 14 "Honorless Target" only this spells have this flag SPELL_ATTR_EX3_IS_HONORLESS_TARGET = 0x00004000, // 14 "Honorless Target" only this spells have this flag
SPELL_ATTR_EX3_UNK15 = 0x00008000, // 15 Auto Shoot, Shoot, Throw, - this is autoshot flag SPELL_ATTR_EX3_RANGED_ATTACK = 0x00008000, // 15 Auto Shoot, Shoot, Throw, - this is autoshot flag
SPELL_ATTR_EX3_UNK16 = 0x00010000, // 16 no triggers effects that trigger on casting a spell?? SPELL_ATTR_EX3_CANT_TRIGGER_PROC = 0x00010000, // 16 confirmed by patchnotes
SPELL_ATTR_EX3_NO_INITIAL_AGGRO = 0x00020000, // 17 Causes no aggro if not missed SPELL_ATTR_EX3_NO_INITIAL_AGGRO = 0x00020000, // 17 Causes no aggro if not missed
SPELL_ATTR_EX3_CANT_MISS = 0x00040000, // 18 Spell should always hit its target SPELL_ATTR_EX3_CANT_MISS = 0x00040000, // 18 Spell should always hit its target
SPELL_ATTR_EX3_UNK19 = 0x00080000, // 19 SPELL_ATTR_EX3_UNK19 = 0x00080000, // 19
@ -411,18 +411,18 @@ enum SpellAttributesEx3
SPELL_ATTR_EX3_UNK23 = 0x00800000, // 23 SPELL_ATTR_EX3_UNK23 = 0x00800000, // 23
SPELL_ATTR_EX3_REQ_OFFHAND = 0x01000000, // 24 Req offhand weapon SPELL_ATTR_EX3_REQ_OFFHAND = 0x01000000, // 24 Req offhand weapon
SPELL_ATTR_EX3_UNK25 = 0x02000000, // 25 no cause spell pushback ? SPELL_ATTR_EX3_UNK25 = 0x02000000, // 25 no cause spell pushback ?
SPELL_ATTR_EX3_UNK26 = 0x04000000, // 26 SPELL_ATTR_EX3_CAN_PROC_FROM_TRIGGERED_SPECIAL = 0x04000000, // 26 Auras with this attribute can proc off SPELL_ATTR_EX3_TRIGGERED_CAN_TRIGGER_SPECIAL
SPELL_ATTR_EX3_UNK27 = 0x08000000, // 27 SPELL_ATTR_EX3_DRAIN_SOUL = 0x08000000, // 27
SPELL_ATTR_EX3_UNK28 = 0x10000000, // 28 always cast ok ? (requires more research) SPELL_ATTR_EX3_UNK28 = 0x10000000, // 28 always cast ok ? (requires more research)
SPELL_ATTR_EX3_UNK29 = 0x20000000, // 29 SPELL_ATTR_EX3_NO_DONE_BONUS = 0x20000000, // 29 Resistances should still affect damage
SPELL_ATTR_EX3_UNK30 = 0x40000000, // 30 SPELL_ATTR_EX3_DONT_DISPLAY_RANGE = 0x40000000, // 30
SPELL_ATTR_EX3_UNK31 = 0x80000000 // 31 SPELL_ATTR_EX3_UNK31 = 0x80000000 // 31
}; };
enum SpellAttributesEx4 enum SpellAttributesEx4
{ {
SPELL_ATTR_EX4_UNK0 = 0x00000001, // 0 SPELL_ATTR_EX4_IGNORE_RESISTANCES = 0x00000001, // 0
SPELL_ATTR_EX4_UNK1 = 0x00000002, // 1 proc on finishing move? SPELL_ATTR_EX4_PROC_ONLY_ON_CASTER = 0x00000002, // 1 Only proc on self-cast
SPELL_ATTR_EX4_UNK2 = 0x00000004, // 2 SPELL_ATTR_EX4_UNK2 = 0x00000004, // 2
SPELL_ATTR_EX4_UNK3 = 0x00000008, // 3 SPELL_ATTR_EX4_UNK3 = 0x00000008, // 3
SPELL_ATTR_EX4_UNK4 = 0x00000010, // 4 This will no longer cause guards to attack on use?? SPELL_ATTR_EX4_UNK4 = 0x00000010, // 4 This will no longer cause guards to attack on use??
@ -430,23 +430,23 @@ enum SpellAttributesEx4
SPELL_ATTR_EX4_NOT_STEALABLE = 0x00000040, // 6 although such auras might be dispellable, they can not be stolen SPELL_ATTR_EX4_NOT_STEALABLE = 0x00000040, // 6 although such auras might be dispellable, they can not be stolen
SPELL_ATTR_EX4_CAN_CAST_WHILE_CASTING = 0x00000080, // 7 In theory, can use this spell while another is channeled/cast/autocast SPELL_ATTR_EX4_CAN_CAST_WHILE_CASTING = 0x00000080, // 7 In theory, can use this spell while another is channeled/cast/autocast
SPELL_ATTR_EX4_STACK_DOT_MODIFIER = 0x00000100, // 8 no effect on non DoTs? SPELL_ATTR_EX4_STACK_DOT_MODIFIER = 0x00000100, // 8 no effect on non DoTs?
SPELL_ATTR_EX4_UNK9 = 0x00000200, // 9 SPELL_ATTR_EX4_TRIGGER_ACTIVATE = 0x00000200, // 9 initially disabled / trigger activate from event (Execute, Riposte, Deep Freeze end other)
SPELL_ATTR_EX4_SPELL_VS_EXTEND_COST = 0x00000400, // 10 Rogue Shiv have this flag SPELL_ATTR_EX4_SPELL_VS_EXTEND_COST = 0x00000400, // 10 Rogue Shiv have this flag
SPELL_ATTR_EX4_UNK11 = 0x00000800, // 11 SPELL_ATTR_EX4_UNK11 = 0x00000800, // 11
SPELL_ATTR_EX4_UNK12 = 0x00001000, // 12 SPELL_ATTR_EX4_UNK12 = 0x00001000, // 12
SPELL_ATTR_EX4_UNK13 = 0x00002000, // 13 SPELL_ATTR_EX4_UNK13 = 0x00002000, // 13
SPELL_ATTR_EX4_UNK14 = 0x00004000, // 14 SPELL_ATTR_EX4_DAMAGE_DOESNT_BREAK_AURAS = 0x00004000, // 14
SPELL_ATTR_EX4_UNK15 = 0x00008000, // 15 SPELL_ATTR_EX4_UNK15 = 0x00008000, // 15
SPELL_ATTR_EX4_NOT_USABLE_IN_ARENA = 0x00010000, // 16 not usable in arena SPELL_ATTR_EX4_NOT_USABLE_IN_ARENA = 0x00010000, // 16 not usable in arena
SPELL_ATTR_EX4_USABLE_IN_ARENA = 0x00020000, // 17 usable in arena SPELL_ATTR_EX4_USABLE_IN_ARENA = 0x00020000, // 17 usable in arena
SPELL_ATTR_EX4_UNK18 = 0x00040000, // 18 SPELL_ATTR_EX4_UNK18 = 0x00040000, // 18
SPELL_ATTR_EX4_UNK19 = 0x00080000, // 19 SPELL_ATTR_EX4_UNK19 = 0x00080000, // 19
SPELL_ATTR_EX4_UNK20 = 0x00100000, // 20 do not give "more powerful spell" error message SPELL_ATTR_EX4_NOT_CHECK_SELFCAST_POWER = 0x00100000, // 20 do not give "more powerful spell" error message
SPELL_ATTR_EX4_UNK21 = 0x00200000, // 21 SPELL_ATTR_EX4_UNK21 = 0x00200000, // 21
SPELL_ATTR_EX4_UNK22 = 0x00400000, // 22 SPELL_ATTR_EX4_UNK22 = 0x00400000, // 22
SPELL_ATTR_EX4_UNK23 = 0x00800000, // 23 SPELL_ATTR_EX4_UNK23 = 0x00800000, // 23
SPELL_ATTR_EX4_UNK24 = 0x01000000, // 24 SPELL_ATTR_EX4_UNK24 = 0x01000000, // 24
SPELL_ATTR_EX4_UNK25 = 0x02000000, // 25 pet scaling auras SPELL_ATTR_EX4_IS_PET_SCALING = 0x02000000, // 25 pet scaling auras
SPELL_ATTR_EX4_CAST_ONLY_IN_OUTLAND = 0x04000000, // 26 Can only be used in Outland. SPELL_ATTR_EX4_CAST_ONLY_IN_OUTLAND = 0x04000000, // 26 Can only be used in Outland.
SPELL_ATTR_EX4_UNK27 = 0x08000000, // 27 SPELL_ATTR_EX4_UNK27 = 0x08000000, // 27
SPELL_ATTR_EX4_UNK28 = 0x10000000, // 28 SPELL_ATTR_EX4_UNK28 = 0x10000000, // 28

View File

@ -1519,7 +1519,7 @@ bool ScriptAction::HandleScriptStep()
float z = m_script->z; float z = m_script->z;
float o = m_script->o; float o = m_script->o;
Creature* pCreature = pSource->SummonCreature(m_script->summonCreature.creatureEntry, x, y, z, o, m_script->summonCreature.despawnDelay ? TEMPSUMMON_TIMED_OOC_OR_DEAD_DESPAWN : TEMPSUMMON_DEAD_DESPAWN, m_script->summonCreature.despawnDelay, (m_script->data_flags & SCRIPT_FLAG_COMMAND_ADDITIONAL) ? true : false, m_script->textId[0] != 0); Creature* pCreature = pSource->SummonCreature(m_script->summonCreature.creatureEntry, x, y, z, o, m_script->summonCreature.despawnDelay ? TEMPSPAWN_TIMED_OOC_OR_DEAD_DESPAWN : TEMPSPAWN_DEAD_DESPAWN, m_script->summonCreature.despawnDelay, (m_script->data_flags & SCRIPT_FLAG_COMMAND_ADDITIONAL) ? true : false, m_script->textId[0] != 0);
if (!pCreature) if (!pCreature)
{ {
sLog.outErrorDb(" DB-SCRIPTS: Process table `db_scripts [type = %d]` id %u, command %u failed for creature (entry: %u).", m_type, m_script->id, m_script->command, m_script->summonCreature.creatureEntry); sLog.outErrorDb(" DB-SCRIPTS: Process table `db_scripts [type = %d]` id %u, command %u failed for creature (entry: %u).", m_type, m_script->id, m_script->command, m_script->summonCreature.creatureEntry);

View File

@ -383,7 +383,7 @@ Spell::Spell(Unit* caster, SpellEntry const* info, bool triggered, ObjectGuid or
// determine reflection // determine reflection
m_canReflect = false; m_canReflect = false;
if (m_spellInfo->DmgClass == SPELL_DAMAGE_CLASS_MAGIC && !m_spellInfo->HasAttribute(SPELL_ATTR_EX2_CANT_REFLECTED)) if (m_spellInfo->DmgClass == SPELL_DAMAGE_CLASS_MAGIC && !m_spellInfo->HasAttribute(SPELL_ATTR_EX2_IGNORE_LOS))
{ {
for (int j = 0; j < MAX_EFFECT_INDEX; ++j) for (int j = 0; j < MAX_EFFECT_INDEX; ++j)
{ {
@ -398,7 +398,7 @@ Spell::Spell(Unit* caster, SpellEntry const* info, bool triggered, ObjectGuid or
} }
else else
{ {
m_canReflect = m_spellInfo->HasAttribute(SPELL_ATTR_EX_NEGATIVE); m_canReflect = m_spellInfo->HasAttribute(SPELL_ATTR_EX_CANT_BE_REFLECTED);
} }
if (m_canReflect) if (m_canReflect)
@ -2829,7 +2829,7 @@ void Spell::SetTargetMap(SpellEffectIndex effIndex, uint32 targetMode, UnitList&
break; break;
case SPELL_EFFECT_APPLY_AREA_AURA_PARTY: case SPELL_EFFECT_APPLY_AREA_AURA_PARTY:
// AreaAura // AreaAura
if ((m_spellInfo->Attributes == (SPELL_ATTR_NOT_SHAPESHIFT | SPELL_ATTR_UNK18 | SPELL_ATTR_CASTABLE_WHILE_MOUNTED | SPELL_ATTR_CASTABLE_WHILE_SITTING)) || (m_spellInfo->Attributes == SPELL_ATTR_NOT_SHAPESHIFT)) if ((m_spellInfo->Attributes == (SPELL_ATTR_NOT_SHAPESHIFT | SPELL_ATTR_DONT_AFFECT_SHEATH_STATE | SPELL_ATTR_CASTABLE_WHILE_MOUNTED | SPELL_ATTR_CASTABLE_WHILE_SITTING)) || (m_spellInfo->Attributes == SPELL_ATTR_NOT_SHAPESHIFT))
{ {
SetTargetMap(effIndex, TARGET_AREAEFFECT_PARTY, targetUnitMap); SetTargetMap(effIndex, TARGET_AREAEFFECT_PARTY, targetUnitMap);
} }
@ -4329,9 +4329,9 @@ void Spell::SendResurrectRequest(Player* target)
data << uint32(strlen(sentName) + 1); data << uint32(strlen(sentName) + 1);
data << sentName; data << sentName;
data << uint8(0); data << uint8(m_caster->isSpiritHealer());
// override delay sent with SMSG_CORPSE_RECLAIM_DELAY, set instant resurrection for spells with this attribute
data << uint8(m_caster->GetTypeId() == TYPEID_PLAYER ? 0 : 1); data << uint8(!m_spellInfo->HasAttribute(SPELL_ATTR_EX3_IGNORE_RESURRECTION_TIMER));
target->GetSession()->SendPacket(&data); target->GetSession()->SendPacket(&data);
} }
@ -4943,7 +4943,7 @@ SpellCastResult Spell::CheckCast(bool strict)
} }
else else
{ {
positive = (holder->GetSpellProto()->AttributesEx & SPELL_ATTR_EX_NEGATIVE) == 0; positive = (holder->GetSpellProto()->AttributesEx & SPELL_ATTR_EX_CANT_BE_REFLECTED) == 0;
} }
// do not remove positive auras if friendly target // do not remove positive auras if friendly target
@ -4979,7 +4979,7 @@ SpellCastResult Spell::CheckCast(bool strict)
// totem immunity for channeled spells(needs to be before spell cast) // totem immunity for channeled spells(needs to be before spell cast)
// spell attribs for player channeled spells // spell attribs for player channeled spells
if (m_spellInfo->HasAttribute(SPELL_ATTR_EX_UNK14) if (m_spellInfo->HasAttribute(SPELL_ATTR_EX_CHANNEL_TRACK_TARGET)
&& target->GetTypeId() == TYPEID_UNIT && target->GetTypeId() == TYPEID_UNIT
&& ((Creature*)target)->IsTotem()) && ((Creature*)target)->IsTotem())
{ {
@ -5191,14 +5191,14 @@ SpellCastResult Spell::CheckCast(bool strict)
} }
// Must be behind the target. // Must be behind the target.
if (m_spellInfo->AttributesEx2 == SPELL_ATTR_EX2_UNK20 && m_spellInfo->HasAttribute(SPELL_ATTR_EX_UNK9) && target->HasInArc(M_PI_F, m_caster)) if (m_spellInfo->AttributesEx2 == SPELL_ATTR_EX2_FACING_TARGETS_BACK && m_spellInfo->HasAttribute(SPELL_ATTR_EX_FACING_TARGET) && target->HasInArc(M_PI_F, m_caster))
{ {
SendInterrupted(SPELL_FAILED_NOT_BEHIND); SendInterrupted(SPELL_FAILED_NOT_BEHIND);
return SPELL_FAILED_NOT_BEHIND; return SPELL_FAILED_NOT_BEHIND;
} }
// Target must be facing you. // Target must be facing you.
if ((m_spellInfo->Attributes == (SPELL_ATTR_UNK4 | SPELL_ATTR_NOT_SHAPESHIFT | SPELL_ATTR_UNK18 | SPELL_ATTR_STOP_ATTACK_TARGET)) && !target->HasInArc(M_PI_F, m_caster)) if ((m_spellInfo->Attributes == (SPELL_ATTR_ABILITY | SPELL_ATTR_NOT_SHAPESHIFT | SPELL_ATTR_DONT_AFFECT_SHEATH_STATE | SPELL_ATTR_STOP_ATTACK_TARGET)) && !target->HasInArc(M_PI_F, m_caster))
{ {
SendInterrupted(SPELL_FAILED_NOT_INFRONT); SendInterrupted(SPELL_FAILED_NOT_INFRONT);
return SPELL_FAILED_NOT_INFRONT; return SPELL_FAILED_NOT_INFRONT;

View File

@ -3971,7 +3971,7 @@ void Aura::HandleModTotalPercentStat(bool apply, bool /*Real*/)
} }
// recalculate current HP/MP after applying aura modifications (only for spells with 0x10 flag) // recalculate current HP/MP after applying aura modifications (only for spells with 0x10 flag)
if (m_modifier.m_miscvalue == STAT_STAMINA && maxHPValue > 0 && GetSpellProto()->HasAttribute(SPELL_ATTR_UNK4)) if (m_modifier.m_miscvalue == STAT_STAMINA && maxHPValue > 0 && GetSpellProto()->HasAttribute(SPELL_ATTR_ABILITY))
{ {
// newHP = (curHP / maxHP) * newMaxHP = (newMaxHP * curHP) / maxHP -> which is better because no int -> double -> int conversion is needed // newHP = (curHP / maxHP) * newMaxHP = (newMaxHP * curHP) / maxHP -> which is better because no int -> double -> int conversion is needed
uint32 newHPValue = (target->GetMaxHealth() * curHPValue) / maxHPValue; uint32 newHPValue = (target->GetMaxHealth() * curHPValue) / maxHPValue;
@ -5125,7 +5125,7 @@ void Aura::PeriodicTick()
// 5..8 ticks have normal tick damage // 5..8 ticks have normal tick damage
} }
target->CalculateDamageAbsorbAndResist(pCaster, GetSpellSchoolMask(spellProto), DOT, pdamage, &absorb, &resist, !spellProto->HasAttribute(SPELL_ATTR_EX2_CANT_REFLECTED)); target->CalculateDamageAbsorbAndResist(pCaster, GetSpellSchoolMask(spellProto), DOT, pdamage, &absorb, &resist, !spellProto->HasAttribute(SPELL_ATTR_EX2_IGNORE_LOS));
DETAIL_FILTER_LOG(LOG_FILTER_PERIODIC_AFFECTS, "PeriodicTick: %s attacked %s for %u dmg inflicted by %u", DETAIL_FILTER_LOG(LOG_FILTER_PERIODIC_AFFECTS, "PeriodicTick: %s attacked %s for %u dmg inflicted by %u",
GetCasterGuid().GetString().c_str(), target->GetGuidStr().c_str(), pdamage, GetId()); GetCasterGuid().GetString().c_str(), target->GetGuidStr().c_str(), pdamage, GetId());
@ -5198,7 +5198,7 @@ void Aura::PeriodicTick()
pdamage = target->SpellDamageBonusTaken(pCaster, spellProto, pdamage, DOT, GetStackAmount()); pdamage = target->SpellDamageBonusTaken(pCaster, spellProto, pdamage, DOT, GetStackAmount());
target->CalculateDamageAbsorbAndResist(pCaster, GetSpellSchoolMask(spellProto), DOT, pdamage, &absorb, &resist, !spellProto->HasAttribute(SPELL_ATTR_EX2_CANT_REFLECTED)); target->CalculateDamageAbsorbAndResist(pCaster, GetSpellSchoolMask(spellProto), DOT, pdamage, &absorb, &resist, !spellProto->HasAttribute(SPELL_ATTR_EX2_IGNORE_LOS));
if (target->GetHealth() < pdamage) if (target->GetHealth() < pdamage)
{ {

View File

@ -2797,7 +2797,7 @@ void Spell::EffectDispel(SpellEffectIndex eff_idx)
} }
else else
{ {
positive = (holder->GetSpellProto()->AttributesEx & SPELL_ATTR_EX_NEGATIVE) == 0; positive = (holder->GetSpellProto()->AttributesEx & SPELL_ATTR_EX_CANT_BE_REFLECTED) == 0;
} }
// do not remove positive auras if friendly target // do not remove positive auras if friendly target
@ -3059,7 +3059,7 @@ void Spell::EffectSummonWild(SpellEffectIndex eff_idx)
float radius = GetSpellRadius(sSpellRadiusStore.LookupEntry(m_spellInfo->EffectRadiusIndex[eff_idx])); float radius = GetSpellRadius(sSpellRadiusStore.LookupEntry(m_spellInfo->EffectRadiusIndex[eff_idx]));
int32 duration = GetSpellDuration(m_spellInfo); int32 duration = GetSpellDuration(m_spellInfo);
TempSummonType summonType = (duration == 0) ? TEMPSUMMON_DEAD_DESPAWN : TEMPSUMMON_TIMED_OOC_OR_DEAD_DESPAWN; TempSpawnType summonType = (duration == 0) ? TEMPSPAWN_DEAD_DESPAWN : TEMPSPAWN_TIMED_OOC_OR_DEAD_DESPAWN;
int32 amount = damage > 0 ? damage : 1; int32 amount = damage > 0 ? damage : 1;
@ -3412,7 +3412,7 @@ void Spell::EffectEnchantItemTmp(SpellEffectIndex eff_idx)
uint32 duration; uint32 duration;
// shaman family enchantments // shaman family enchantments
if (m_spellInfo->Attributes == (SPELL_ATTR_UNK9 | SPELL_ATTR_NOT_SHAPESHIFT | SPELL_ATTR_UNK18)) if (m_spellInfo->Attributes == (SPELL_ATTR_TARGET_MAINHAND_ITEM | SPELL_ATTR_NOT_SHAPESHIFT | SPELL_ATTR_DONT_AFFECT_SHEATH_STATE))
{ {
duration = 300; // 5 mins duration = 300; // 5 mins
} }
@ -3427,7 +3427,7 @@ void Spell::EffectEnchantItemTmp(SpellEffectIndex eff_idx)
duration = 3600; // 1 hour duration = 3600; // 1 hour
} }
// some fishing pole bonuses // some fishing pole bonuses
else if (m_spellInfo->HasAttribute(SPELL_ATTR_HIDE_SPELL)) else if (m_spellInfo->HasAttribute(SPELL_ATTR_HIDDEN_CLIENTSIDE))
{ {
duration = 600; // 10 mins duration = 600; // 10 mins
} }
@ -4892,7 +4892,7 @@ void Spell::EffectActivateObject(SpellEffectIndex eff_idx)
case 24790: npcEntry = 15305; break; case 24790: npcEntry = 15305; break;
} }
gameObjTarget->SummonCreature(npcEntry, gameObjTarget->GetPositionX(), gameObjTarget->GetPositionY(), gameObjTarget->GetPositionZ(), gameObjTarget->GetAngle(m_caster), TEMPSUMMON_TIMED_OOC_OR_DEAD_DESPAWN, MINUTE * IN_MILLISECONDS); gameObjTarget->SummonCreature(npcEntry, gameObjTarget->GetPositionX(), gameObjTarget->GetPositionY(), gameObjTarget->GetPositionZ(), gameObjTarget->GetAngle(m_caster), TEMPSPAWN_TIMED_OOC_OR_DEAD_DESPAWN, MINUTE * IN_MILLISECONDS);
gameObjTarget->SetLootState(GO_JUST_DEACTIVATED); gameObjTarget->SetLootState(GO_JUST_DEACTIVATED);
break; break;
} }
@ -4990,7 +4990,7 @@ void Spell::EffectSummonPossessed(SpellEffectIndex eff_idx)
return; return;
} }
Creature* spawnCreature = m_caster->SummonCreature(creatureEntry, m_targets.m_destX, m_targets.m_destY, m_targets.m_destZ, m_caster->GetOrientation(), TEMPSUMMON_CORPSE_DESPAWN, 0); Creature* spawnCreature = m_caster->SummonCreature(creatureEntry, m_targets.m_destX, m_targets.m_destY, m_targets.m_destZ, m_caster->GetOrientation(), TEMPSPAWN_CORPSE_DESPAWN, 0);
if (!spawnCreature) if (!spawnCreature)
{ {
sLog.outError("Spell::DoSummonPossessed: creature entry %u for spell %u could not be summoned.", creatureEntry, m_spellInfo->Id); sLog.outError("Spell::DoSummonPossessed: creature entry %u for spell %u could not be summoned.", creatureEntry, m_spellInfo->Id);
@ -6123,7 +6123,7 @@ void Spell::EffectSummonDemon(SpellEffectIndex eff_idx)
float py = m_targets.m_destY; float py = m_targets.m_destY;
float pz = m_targets.m_destZ; float pz = m_targets.m_destZ;
Creature* Charmed = m_caster->SummonCreature(m_spellInfo->EffectMiscValue[eff_idx], px, py, pz, m_caster->GetOrientation(), TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 3600000); Creature* Charmed = m_caster->SummonCreature(m_spellInfo->EffectMiscValue[eff_idx], px, py, pz, m_caster->GetOrientation(), TEMPSPAWN_TIMED_OR_DEAD_DESPAWN, 3600000);
if (!Charmed) if (!Charmed)
{ {
return; return;

View File

@ -1595,7 +1595,7 @@ SpellAuraProcResult Unit::HandleRemoveByDamageChanceProc(Unit* pVictim, uint32 d
SpellAuraProcResult Unit::HandleInvisibilityAuraProc(Unit* pVictim, uint32 damage, Aura* triggeredByAura, SpellEntry const *procSpell, uint32 procFlag, uint32 procEx, uint32 cooldown) SpellAuraProcResult Unit::HandleInvisibilityAuraProc(Unit* pVictim, uint32 damage, Aura* triggeredByAura, SpellEntry const *procSpell, uint32 procFlag, uint32 procEx, uint32 cooldown)
{ {
if (triggeredByAura->GetSpellProto()->HasAttribute(SPELL_ATTR_PASSIVE) || triggeredByAura->GetSpellProto()->HasAttribute(SPELL_ATTR_EX_NEGATIVE)) if (triggeredByAura->GetSpellProto()->HasAttribute(SPELL_ATTR_PASSIVE) || triggeredByAura->GetSpellProto()->HasAttribute(SPELL_ATTR_EX_CANT_BE_REFLECTED))
{ {
return SPELL_AURA_PROC_FAILED; return SPELL_AURA_PROC_FAILED;
} }