mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 04:37:00 +00:00
[10747] Some other aura caster object guid use cases.
This commit is contained in:
parent
f034a9bd0a
commit
12b80fec68
9 changed files with 67 additions and 67 deletions
|
|
@ -659,7 +659,7 @@ void Creature::DoFleeToGetAssistance()
|
|||
UpdateSpeed(MOVE_RUN, false);
|
||||
|
||||
if(!pCreature)
|
||||
SetFeared(true, getVictim()->GetGUID(), 0 ,sWorld.getConfig(CONFIG_UINT32_CREATURE_FAMILY_FLEE_DELAY));
|
||||
SetFeared(true, getVictim()->GetObjectGuid(), 0 ,sWorld.getConfig(CONFIG_UINT32_CREATURE_FAMILY_FLEE_DELAY));
|
||||
else
|
||||
GetMotionMaster()->MoveSeekAssistance(pCreature->GetPositionX(), pCreature->GetPositionY(), pCreature->GetPositionZ());
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6887,7 +6887,7 @@ void Player::DuelComplete(DuelCompleteType type)
|
|||
SpellAuraHolderMap const& vAuras = duel->opponent->GetSpellAuraHolderMap();
|
||||
for (SpellAuraHolderMap::const_iterator i = vAuras.begin(); i != vAuras.end(); ++i)
|
||||
{
|
||||
if (!i->second->IsPositive() && i->second->GetCasterGUID() == GetGUID() && i->second->GetAuraApplyTime() >= duel->startTime)
|
||||
if (!i->second->IsPositive() && i->second->GetCasterGuid() == GetObjectGuid() && i->second->GetAuraApplyTime() >= duel->startTime)
|
||||
auras2remove.push_back(i->second->GetId());
|
||||
}
|
||||
|
||||
|
|
@ -6898,7 +6898,7 @@ void Player::DuelComplete(DuelCompleteType type)
|
|||
SpellAuraHolderMap const& auras = GetSpellAuraHolderMap();
|
||||
for (SpellAuraHolderMap::const_iterator i = auras.begin(); i != auras.end(); ++i)
|
||||
{
|
||||
if (!i->second->IsPositive() && i->second->GetCasterGUID() == duel->opponent->GetGUID() && i->second->GetAuraApplyTime() >= duel->startTime)
|
||||
if (!i->second->IsPositive() && i->second->GetCasterGuid() == duel->opponent->GetObjectGuid() && i->second->GetAuraApplyTime() >= duel->startTime)
|
||||
auras2remove.push_back(i->second->GetId());
|
||||
}
|
||||
for(size_t i=0; i<auras2remove.size(); ++i)
|
||||
|
|
|
|||
|
|
@ -1071,7 +1071,7 @@ void Spell::DoAllEffectOnTarget(TargetInfo *target)
|
|||
for(Unit::SpellAuraHolderMap::const_iterator itr = auras.begin(); itr!=auras.end(); ++itr)
|
||||
{
|
||||
if(itr->second->GetSpellProto()->Dispel == DISPEL_DISEASE &&
|
||||
itr->second->GetCasterGUID() == caster->GetGUID())
|
||||
itr->second->GetCasterGuid() == caster->GetObjectGuid())
|
||||
++count;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1911,17 +1911,17 @@ void Aura::TriggerSpell()
|
|||
|
||||
void Aura::TriggerSpellWithValue()
|
||||
{
|
||||
const uint64& casterGUID = GetCasterGUID();
|
||||
ObjectGuid casterGuid = GetCasterGuid();
|
||||
Unit* target = GetTriggerTarget();
|
||||
|
||||
if(!casterGUID || !target)
|
||||
if (casterGuid.IsEmpty() || !target)
|
||||
return;
|
||||
|
||||
// generic casting code with custom spells and target/caster customs
|
||||
uint32 trigger_spell_id = GetSpellProto()->EffectTriggerSpell[m_effIndex];
|
||||
int32 basepoints0 = GetModifier()->m_amount;
|
||||
|
||||
target->CastCustomSpell(target, trigger_spell_id, &basepoints0, NULL, NULL, true, NULL, this, casterGUID);
|
||||
target->CastCustomSpell(target, trigger_spell_id, &basepoints0, NULL, NULL, true, NULL, this, casterGuid);
|
||||
}
|
||||
|
||||
/*********************************************************/
|
||||
|
|
@ -2340,7 +2340,7 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
|
|||
return;
|
||||
|
||||
for (uint32 i = 0; i < spell->StackAmount; ++i)
|
||||
caster->CastSpell(target, spellId, true, NULL, NULL, GetCasterGUID());
|
||||
caster->CastSpell(target, spellId, true, NULL, NULL, GetCasterGuid());
|
||||
|
||||
return;
|
||||
}
|
||||
|
|
@ -2358,7 +2358,7 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
|
|||
return;
|
||||
|
||||
for (uint32 i=0; i < spell->StackAmount; ++i)
|
||||
caster->CastSpell(target, spell->Id, true, NULL, NULL, GetCasterGUID());
|
||||
caster->CastSpell(target, spell->Id, true, NULL, NULL, GetCasterGuid());
|
||||
|
||||
return;
|
||||
}
|
||||
|
|
@ -2465,7 +2465,7 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
|
|||
return;
|
||||
}
|
||||
case 47178: // Plague Effect Self
|
||||
target->SetFeared(apply, GetCasterGUID(), GetId());
|
||||
target->SetFeared(apply, GetCasterGuid(), GetId());
|
||||
return;
|
||||
case 58204: // LK Intro VO (1)
|
||||
if (target->GetTypeId() == TYPEID_PLAYER)
|
||||
|
|
@ -2606,12 +2606,12 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
|
|||
if (target->IsInWorld() && GetStackAmount() > 0)
|
||||
{
|
||||
int32 amount = m_modifier.m_amount;
|
||||
target->CastCustomSpell(target, 33778, &amount, NULL, NULL, true, NULL, this, GetCasterGUID());
|
||||
target->CastCustomSpell(target, 33778, &amount, NULL, NULL, true, NULL, this, GetCasterGuid());
|
||||
|
||||
if (Unit* caster = GetCaster())
|
||||
{
|
||||
int32 returnmana = (GetSpellProto()->ManaCostPercentage * caster->GetCreateMana() / 100) * GetStackAmount() / 2;
|
||||
caster->CastCustomSpell(caster, 64372, &returnmana, NULL, NULL, true, NULL, this, GetCasterGUID());
|
||||
caster->CastCustomSpell(caster, 64372, &returnmana, NULL, NULL, true, NULL, this, GetCasterGuid());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -3215,7 +3215,7 @@ void Aura::HandleAuraTransform(bool apply, bool Real)
|
|||
{
|
||||
// for players, start regeneration after 1s (in polymorph fast regeneration case)
|
||||
// only if caster is Player (after patch 2.4.2)
|
||||
if (IS_PLAYER_GUID(GetCasterGUID()) )
|
||||
if (GetCasterGuid().IsPlayer())
|
||||
((Player*)target)->setRegenTimer(1*IN_MILLISECONDS);
|
||||
|
||||
//dismount polymorphed target (after patch 2.4.2)
|
||||
|
|
@ -3439,7 +3439,7 @@ void Aura::HandleModPossess(bool apply, bool Real)
|
|||
Unit *target = GetTarget();
|
||||
|
||||
// not possess yourself
|
||||
if(GetCasterGUID() == target->GetGUID())
|
||||
if (GetCasterGuid() == target->GetObjectGuid())
|
||||
return;
|
||||
|
||||
Unit* caster = GetCaster();
|
||||
|
|
@ -3623,7 +3623,7 @@ void Aura::HandleModCharm(bool apply, bool Real)
|
|||
Unit *target = GetTarget();
|
||||
|
||||
// not charm yourself
|
||||
if(GetCasterGUID() == target->GetGUID())
|
||||
if (GetCasterGuid() == target->GetObjectGuid())
|
||||
return;
|
||||
|
||||
Unit* caster = GetCaster();
|
||||
|
|
@ -3738,7 +3738,7 @@ void Aura::HandleModConfuse(bool apply, bool Real)
|
|||
if(!Real)
|
||||
return;
|
||||
|
||||
GetTarget()->SetConfused(apply, GetCasterGUID(), GetId());
|
||||
GetTarget()->SetConfused(apply, GetCasterGuid(), GetId());
|
||||
}
|
||||
|
||||
void Aura::HandleModFear(bool apply, bool Real)
|
||||
|
|
@ -3746,7 +3746,7 @@ void Aura::HandleModFear(bool apply, bool Real)
|
|||
if (!Real)
|
||||
return;
|
||||
|
||||
GetTarget()->SetFeared(apply, GetCasterGUID(), GetId());
|
||||
GetTarget()->SetFeared(apply, GetCasterGuid(), GetId());
|
||||
}
|
||||
|
||||
void Aura::HandleFeignDeath(bool apply, bool Real)
|
||||
|
|
@ -3754,7 +3754,7 @@ void Aura::HandleFeignDeath(bool apply, bool Real)
|
|||
if(!Real)
|
||||
return;
|
||||
|
||||
GetTarget()->SetFeignDeath(apply, GetCasterGUID(), GetId());
|
||||
GetTarget()->SetFeignDeath(apply, GetCasterGuid(), GetId());
|
||||
}
|
||||
|
||||
void Aura::HandleAuraModDisarm(bool apply, bool Real)
|
||||
|
|
@ -3806,7 +3806,7 @@ void Aura::HandleAuraModStun(bool apply, bool Real)
|
|||
target->SetTargetGuid(ObjectGuid());
|
||||
|
||||
target->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_STUNNED);
|
||||
target->CastStop(target->GetGUID() == GetCasterGUID() ? GetId() : 0);
|
||||
target->CastStop(target->GetObjectGuid() == GetCasterGuid() ? GetId() : 0);
|
||||
|
||||
// Creature specific
|
||||
if(target->GetTypeId() != TYPEID_PLAYER)
|
||||
|
|
@ -5100,7 +5100,7 @@ void Aura::HandleAuraModDispelResist(bool apply, bool Real)
|
|||
return;
|
||||
|
||||
if(GetId() == 33206)
|
||||
GetTarget()->CastSpell(GetTarget(), 44416, true, NULL, this, GetCasterGUID());
|
||||
GetTarget()->CastSpell(GetTarget(), 44416, true, NULL, this, GetCasterGuid());
|
||||
}
|
||||
|
||||
void Aura::HandleModSpellDamagePercentFromAttackPower(bool /*apply*/, bool /*Real*/)
|
||||
|
|
@ -6393,10 +6393,10 @@ void Aura::HandleSchoolAbsorb(bool apply, bool Real)
|
|||
switch(target->getPowerType())
|
||||
{
|
||||
case POWER_RUNIC_POWER:
|
||||
target->CastSpell(target, 63652, true, NULL, NULL, GetCasterGUID());
|
||||
target->CastSpell(target, 63652, true, NULL, NULL, GetCasterGuid());
|
||||
break;
|
||||
case POWER_RAGE:
|
||||
target->CastSpell(target, 63653, true, NULL, NULL, GetCasterGUID());
|
||||
target->CastSpell(target, 63653, true, NULL, NULL, GetCasterGuid());
|
||||
break;
|
||||
case POWER_MANA:
|
||||
{
|
||||
|
|
@ -6405,7 +6405,7 @@ void Aura::HandleSchoolAbsorb(bool apply, bool Real)
|
|||
break;
|
||||
}
|
||||
case POWER_ENERGY:
|
||||
target->CastSpell(target, 63655, true, NULL, NULL, GetCasterGUID());
|
||||
target->CastSpell(target, 63655, true, NULL, NULL, GetCasterGuid());
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
@ -6635,7 +6635,7 @@ void Aura::PeriodicTick()
|
|||
|
||||
// only from players
|
||||
// FIXME: need use SpellDamageBonus instead?
|
||||
if (IS_PLAYER_GUID(GetCasterGUID()))
|
||||
if (GetCasterGuid().IsPlayer())
|
||||
pdamage -= target->GetSpellDamageReduction(pdamage);
|
||||
|
||||
target->CalculateDamageAbsorbAndResist(pCaster, GetSpellSchoolMask(spellProto), DOT, pdamage, &absorb, &resist, !(spellProto->AttributesEx2 & SPELL_ATTR_EX2_CANT_REFLECTED));
|
||||
|
|
@ -7384,7 +7384,7 @@ void Aura::PeriodicDummyTick()
|
|||
// Explosive Shot
|
||||
if (spell->SpellFamilyFlags & UI64LIT(0x8000000000000000))
|
||||
{
|
||||
target->CastCustomSpell(target, 53352, &m_modifier.m_amount, 0, 0, true, 0, this, GetCasterGUID());
|
||||
target->CastCustomSpell(target, 53352, &m_modifier.m_amount, 0, 0, true, 0, this, GetCasterGuid());
|
||||
return;
|
||||
}
|
||||
switch (spell->Id)
|
||||
|
|
@ -7482,7 +7482,7 @@ void Aura::HandlePreventFleeing(bool apply, bool Real)
|
|||
if( !fearAuras.empty() )
|
||||
{
|
||||
if (apply)
|
||||
GetTarget()->SetFeared(false, fearAuras.front()->GetCasterGUID());
|
||||
GetTarget()->SetFeared(false, fearAuras.front()->GetCasterGuid());
|
||||
else
|
||||
GetTarget()->SetFeared(true);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2566,7 +2566,7 @@ void Spell::EffectDummy(SpellEffectIndex eff_idx)
|
|||
for(Unit::SpellAuraHolderMap::const_iterator itr = auras.begin(); itr!=auras.end(); ++itr)
|
||||
{
|
||||
if (itr->second->GetSpellProto()->Dispel == DISPEL_DISEASE &&
|
||||
itr->second->GetCasterGUID() == m_caster->GetGUID())
|
||||
itr->second->GetCasterGuid() == m_caster->GetObjectGuid())
|
||||
{
|
||||
++count;
|
||||
// max. 15%
|
||||
|
|
@ -5388,7 +5388,7 @@ void Spell::EffectWeaponDmg(SpellEffectIndex eff_idx)
|
|||
for(Unit::SpellAuraHolderMap::const_iterator itr = auras.begin(); itr!=auras.end(); ++itr)
|
||||
{
|
||||
if(itr->second->GetSpellProto()->Dispel == DISPEL_DISEASE &&
|
||||
itr->second->GetCasterGUID() == m_caster->GetGUID())
|
||||
itr->second->GetCasterGuid() == m_caster->GetObjectGuid())
|
||||
++count;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -4173,10 +4173,10 @@ bool Unit::RemoveNoStackAurasDueToAuraHolder(SpellAuraHolder *holder)
|
|||
uint32 i_spellId = i_spellProto->Id;
|
||||
|
||||
// early checks that spellId is passive non stackable spell
|
||||
if(IsPassiveSpell(i_spellProto))
|
||||
if (IsPassiveSpell(i_spellProto))
|
||||
{
|
||||
// passive non-stackable spells not stackable only for same caster
|
||||
if(holder->GetCasterGUID()!=i->second->GetCasterGUID())
|
||||
if (holder->GetCasterGuid() != i->second->GetCasterGuid())
|
||||
continue;
|
||||
|
||||
// passive non-stackable spells not stackable only with another rank of same spell
|
||||
|
|
@ -4597,9 +4597,9 @@ void Unit::RemoveNotOwnSingleTargetAuras(uint32 newPhase)
|
|||
// single target auras from other casters
|
||||
for (SpellAuraHolderMap::iterator iter = m_spellAuraHolders.begin(); iter != m_spellAuraHolders.end(); )
|
||||
{
|
||||
if (iter->second->GetCasterGUID() != GetGUID() && iter->second->IsSingleTarget())
|
||||
if (iter->second->GetCasterGuid() != GetObjectGuid() && iter->second->IsSingleTarget())
|
||||
{
|
||||
if(!newPhase)
|
||||
if (!newPhase)
|
||||
{
|
||||
RemoveSpellAuraHolder(iter->second);
|
||||
iter = m_spellAuraHolders.begin();
|
||||
|
|
@ -4608,7 +4608,7 @@ void Unit::RemoveNotOwnSingleTargetAuras(uint32 newPhase)
|
|||
else
|
||||
{
|
||||
Unit* caster = iter->second->GetCaster();
|
||||
if(!caster || !caster->InSamePhase(newPhase))
|
||||
if (!caster || !caster->InSamePhase(newPhase))
|
||||
{
|
||||
RemoveSpellAuraHolder(iter->second);
|
||||
iter = m_spellAuraHolders.begin();
|
||||
|
|
@ -5100,7 +5100,7 @@ void Unit::SendPeriodicAuraLog(SpellPeriodicAuraLogInfo *pInfo)
|
|||
|
||||
WorldPacket data(SMSG_PERIODICAURALOG, 30);
|
||||
data << aura->GetTarget()->GetPackGUID();
|
||||
data.appendPackGUID(aura->GetCasterGUID());
|
||||
data << aura->GetCasterGuid().WriteAsPacked();
|
||||
data << uint32(aura->GetId()); // spellId
|
||||
data << uint32(1); // count
|
||||
data << uint32(mod->m_auraname); // auraId
|
||||
|
|
@ -6472,7 +6472,7 @@ uint32 Unit::SpellDamageBonusTaken(Unit *pCaster, SpellEntry const *spellProto,
|
|||
AuraList const& mOwnerTaken = GetAurasByType(SPELL_AURA_MOD_DAMAGE_FROM_CASTER);
|
||||
for(AuraList::const_iterator i = mOwnerTaken.begin(); i != mOwnerTaken.end(); ++i)
|
||||
{
|
||||
if ((*i)->GetCasterGUID() == pCaster->GetGUID() && (*i)->isAffectedOnSpell(spellProto))
|
||||
if ((*i)->GetCasterGuid() == pCaster->GetObjectGuid() && (*i)->isAffectedOnSpell(spellProto))
|
||||
TakenTotalMod *= ((*i)->GetModifier()->m_amount + 100.0f) / 100.0f;
|
||||
}
|
||||
|
||||
|
|
@ -6663,7 +6663,7 @@ bool Unit::IsSpellCrit(Unit *pVictim, SpellEntry const *spellProto, SpellSchoolM
|
|||
if (spellProto->SpellFamilyFlags & UI64LIT(0x0000000040000000))
|
||||
{
|
||||
Aura *aura = pVictim->GetDummyAura(58597);
|
||||
if (aura && aura->GetCasterGUID() == GetGUID())
|
||||
if (aura && aura->GetCasterGuid() == GetObjectGuid())
|
||||
crit_chance+=aura->GetModifier()->m_amount;
|
||||
}
|
||||
// Exorcism
|
||||
|
|
@ -6852,7 +6852,7 @@ uint32 Unit::SpellHealingBonusDone(Unit *pVictim, SpellEntry const *spellProto,
|
|||
Unit::AuraList const& RejorRegr = pVictim->GetAurasByType(SPELL_AURA_PERIODIC_HEAL);
|
||||
for(Unit::AuraList::const_iterator i = RejorRegr.begin(); i != RejorRegr.end(); ++i)
|
||||
if ((*i)->GetSpellProto()->SpellFamilyName == SPELLFAMILY_DRUID &&
|
||||
(*i)->GetCasterGUID() == GetGUID())
|
||||
(*i)->GetCasterGuid() == GetObjectGuid())
|
||||
++ownHotCount;
|
||||
|
||||
if (ownHotCount)
|
||||
|
|
@ -6877,7 +6877,7 @@ uint32 Unit::SpellHealingBonusDone(Unit *pVictim, SpellEntry const *spellProto,
|
|||
Unit::AuraList const& RejorRegr = pVictim->GetAurasByType(SPELL_AURA_PERIODIC_HEAL);
|
||||
for(Unit::AuraList::const_iterator i = RejorRegr.begin(); i != RejorRegr.end(); ++i)
|
||||
if ((*i)->GetSpellProto()->SpellFamilyName == SPELLFAMILY_DRUID &&
|
||||
(*i)->GetCasterGUID() == GetGUID())
|
||||
(*i)->GetCasterGuid() == GetObjectGuid())
|
||||
++ownHotCount;
|
||||
|
||||
if (ownHotCount)
|
||||
|
|
@ -9843,9 +9843,9 @@ void Unit::StopMoving()
|
|||
SendHeartBeat(false);
|
||||
}
|
||||
|
||||
void Unit::SetFeared(bool apply, uint64 const& casterGUID, uint32 spellID, uint32 time)
|
||||
void Unit::SetFeared(bool apply, ObjectGuid casterGuid, uint32 spellID, uint32 time)
|
||||
{
|
||||
if( apply )
|
||||
if (apply)
|
||||
{
|
||||
if (HasAuraType(SPELL_AURA_PREVENTS_FLEEING))
|
||||
return;
|
||||
|
|
@ -9853,9 +9853,9 @@ void Unit::SetFeared(bool apply, uint64 const& casterGUID, uint32 spellID, uint3
|
|||
SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_FLEEING);
|
||||
|
||||
GetMotionMaster()->MovementExpired(false);
|
||||
CastStop(GetGUID() == casterGUID ? spellID : 0);
|
||||
CastStop(GetObjectGuid() == casterGuid ? spellID : 0);
|
||||
|
||||
Unit* caster = IsInWorld() ? GetMap()->GetUnit(casterGUID) : NULL;
|
||||
Unit* caster = IsInWorld() ? GetMap()->GetUnit(casterGuid) : NULL;
|
||||
|
||||
GetMotionMaster()->MoveFleeing(caster, time); // caster==NULL processed in MoveFleeing
|
||||
}
|
||||
|
|
@ -9875,7 +9875,7 @@ void Unit::SetFeared(bool apply, uint64 const& casterGUID, uint32 spellID, uint3
|
|||
GetMotionMaster()->Initialize();
|
||||
|
||||
// attack caster if can
|
||||
if (Unit* caster = IsInWorld() ? GetMap()->GetUnit(casterGUID) : NULL)
|
||||
if (Unit* caster = IsInWorld() ? GetMap()->GetUnit(casterGuid) : NULL)
|
||||
if (c->AI())
|
||||
c->AI()->AttackedBy(caster);
|
||||
}
|
||||
|
|
@ -9885,13 +9885,13 @@ void Unit::SetFeared(bool apply, uint64 const& casterGUID, uint32 spellID, uint3
|
|||
((Player*)this)->SetClientControl(this, !apply);
|
||||
}
|
||||
|
||||
void Unit::SetConfused(bool apply, uint64 const& casterGUID, uint32 spellID)
|
||||
void Unit::SetConfused(bool apply, ObjectGuid casterGuid, uint32 spellID)
|
||||
{
|
||||
if( apply )
|
||||
if (apply)
|
||||
{
|
||||
SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_CONFUSED);
|
||||
|
||||
CastStop(GetGUID()==casterGUID ? spellID : 0);
|
||||
CastStop(GetObjectGuid() == casterGuid ? spellID : 0);
|
||||
|
||||
GetMotionMaster()->MoveConfused();
|
||||
}
|
||||
|
|
@ -9915,9 +9915,9 @@ void Unit::SetConfused(bool apply, uint64 const& casterGUID, uint32 spellID)
|
|||
((Player*)this)->SetClientControl(this, !apply);
|
||||
}
|
||||
|
||||
void Unit::SetFeignDeath(bool apply, uint64 const& casterGUID, uint32 /*spellID*/)
|
||||
void Unit::SetFeignDeath(bool apply, ObjectGuid casterGuid, uint32 /*spellID*/)
|
||||
{
|
||||
if( apply )
|
||||
if (apply)
|
||||
{
|
||||
/*
|
||||
WorldPacket data(SMSG_FEIGN_DEATH_RESISTED, 9);
|
||||
|
|
@ -9926,7 +9926,7 @@ void Unit::SetFeignDeath(bool apply, uint64 const& casterGUID, uint32 /*spellID*
|
|||
SendMessageToSet(&data,true);
|
||||
*/
|
||||
|
||||
if(GetTypeId() != TYPEID_PLAYER)
|
||||
if (GetTypeId() != TYPEID_PLAYER)
|
||||
StopMoving();
|
||||
else
|
||||
((Player*)this)->m_movementInfo.SetMovementFlags(MOVEFLAG_NONE);
|
||||
|
|
@ -9943,7 +9943,7 @@ void Unit::SetFeignDeath(bool apply, uint64 const& casterGUID, uint32 /*spellID*
|
|||
RemoveAurasWithInterruptFlags(AURA_INTERRUPT_FLAG_IMMUNE_OR_LOST_SELECTION);
|
||||
|
||||
// prevent interrupt message
|
||||
if (casterGUID == GetGUID())
|
||||
if (casterGuid == GetObjectGuid())
|
||||
FinishSpell(CURRENT_GENERIC_SPELL,false);
|
||||
InterruptNonMeleeSpells(true);
|
||||
getHostileRefManager().deleteReferences();
|
||||
|
|
|
|||
|
|
@ -1893,9 +1893,9 @@ class MANGOS_DLL_SPEC Unit : public WorldObject
|
|||
bool IsStopped() const { return !(hasUnitState(UNIT_STAT_MOVING)); }
|
||||
void StopMoving();
|
||||
|
||||
void SetFeared(bool apply, uint64 const& casterGUID = 0, uint32 spellID = 0, uint32 time = 0);
|
||||
void SetConfused(bool apply, uint64 const& casterGUID = 0, uint32 spellID = 0);
|
||||
void SetFeignDeath(bool apply, uint64 const& casterGUID = 0, uint32 spellID = 0);
|
||||
void SetFeared(bool apply, ObjectGuid casterGuid = ObjectGuid(), uint32 spellID = 0, uint32 time = 0);
|
||||
void SetConfused(bool apply, ObjectGuid casterGuid = ObjectGuid(), uint32 spellID = 0);
|
||||
void SetFeignDeath(bool apply, ObjectGuid casterGuid = ObjectGuid(), uint32 spellID = 0);
|
||||
|
||||
void AddComboPointHolder(uint32 lowguid) { m_ComboPointHolders.insert(lowguid); }
|
||||
void RemoveComboPointHolder(uint32 lowguid) { m_ComboPointHolders.erase(lowguid); }
|
||||
|
|
|
|||
|
|
@ -1203,7 +1203,7 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
|||
if( mod->m_amount <= (int32)damage || GetHealth() <= damage )
|
||||
{
|
||||
// remember guid before aura delete
|
||||
uint64 casterGuid = triggeredByAura->GetCasterGUID();
|
||||
ObjectGuid casterGuid = triggeredByAura->GetCasterGuid();
|
||||
|
||||
// Remove aura (before cast for prevent infinite loop handlers)
|
||||
RemoveAurasDueToSpell(triggeredByAura->GetId());
|
||||
|
|
@ -1225,7 +1225,7 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
|||
if( mod->m_amount <= (int32)damage )
|
||||
{
|
||||
// remember guid before aura delete
|
||||
uint64 casterGuid = triggeredByAura->GetCasterGUID();
|
||||
ObjectGuid casterGuid = triggeredByAura->GetCasterGuid();
|
||||
|
||||
// Remove aura (before cast for prevent infinite loop handlers)
|
||||
RemoveAurasDueToSpell(triggeredByAura->GetId());
|
||||
|
|
@ -1313,15 +1313,15 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
|||
// Vampiric Touch
|
||||
if (dummySpell->SpellFamilyFlags & UI64LIT(0x0000040000000000))
|
||||
{
|
||||
if(!pVictim || !pVictim->isAlive())
|
||||
if (!pVictim || !pVictim->isAlive())
|
||||
return SPELL_AURA_PROC_FAILED;
|
||||
|
||||
// pVictim is caster of aura
|
||||
if(triggeredByAura->GetCasterGUID() != pVictim->GetGUID())
|
||||
if (triggeredByAura->GetCasterGuid() != pVictim->GetObjectGuid())
|
||||
return SPELL_AURA_PROC_FAILED;
|
||||
|
||||
// Energize 0.25% of max. mana
|
||||
pVictim->CastSpell(pVictim,57669,true,castItem,triggeredByAura);
|
||||
pVictim->CastSpell(pVictim, 57669, true, castItem, triggeredByAura);
|
||||
return SPELL_AURA_PROC_OK; // no hidden cooldown
|
||||
}
|
||||
|
||||
|
|
@ -1477,7 +1477,7 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
|||
target = this;
|
||||
|
||||
// mana to caster
|
||||
if (triggeredByAura->GetCasterGUID() == GetGUID())
|
||||
if (triggeredByAura->GetCasterGuid() == GetObjectGuid())
|
||||
{
|
||||
if (SpellEntry const* manaCastEntry = sSpellStore.LookupEntry(60889))
|
||||
{
|
||||
|
|
@ -1900,7 +1900,7 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
|||
AuraList const& auras = target->GetAurasByType(SPELL_AURA_PERIODIC_DAMAGE);
|
||||
for(AuraList::const_iterator itr = auras.begin(); itr!=auras.end(); ++itr)
|
||||
{
|
||||
if( ((*itr)->GetId() == 31803) && (*itr)->GetCasterGUID()==GetGUID())
|
||||
if (((*itr)->GetId() == 31803) && (*itr)->GetCasterGuid() == GetObjectGuid())
|
||||
{
|
||||
stacks = (*itr)->GetStackAmount();
|
||||
break;
|
||||
|
|
@ -1956,7 +1956,7 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
|||
case 53651:
|
||||
{
|
||||
// not do bonus heal for explicit beacon focus healing
|
||||
if (GetGUID() == triggeredByAura->GetCasterGUID())
|
||||
if (GetObjectGuid() == triggeredByAura->GetCasterGuid())
|
||||
return SPELL_AURA_PROC_FAILED;
|
||||
|
||||
// beacon
|
||||
|
|
@ -1969,7 +1969,7 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
|||
Unit::AuraList const& baa = beacon->GetAurasByType(SPELL_AURA_PERIODIC_TRIGGER_SPELL);
|
||||
for(Unit::AuraList::const_iterator i = baa.begin(); i != baa.end(); ++i)
|
||||
{
|
||||
if ((*i)->GetId() == 53563 && (*i)->GetCasterGUID() == pVictim->GetGUID())
|
||||
if ((*i)->GetId() == 53563 && (*i)->GetCasterGuid() == pVictim->GetObjectGuid())
|
||||
{
|
||||
dummy = (*i);
|
||||
break;
|
||||
|
|
@ -2002,7 +2002,7 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
|
|||
AuraList const& auras = target->GetAurasByType(SPELL_AURA_PERIODIC_DAMAGE);
|
||||
for(AuraList::const_iterator itr = auras.begin(); itr!=auras.end(); ++itr)
|
||||
{
|
||||
if( ((*itr)->GetId() == 53742) && (*itr)->GetCasterGUID()==GetGUID())
|
||||
if (((*itr)->GetId() == 53742) && (*itr)->GetCasterGuid() == GetObjectGuid())
|
||||
{
|
||||
stacks = (*itr)->GetStackAmount();
|
||||
break;
|
||||
|
|
@ -3618,7 +3618,7 @@ SpellAuraProcResult Unit::HandleMendingAuraProc( Unit* /*pVictim*/, uint32 /*dam
|
|||
SpellEntry const* spellProto = triggeredByAura->GetSpellProto();
|
||||
SpellEffectIndex effIdx = triggeredByAura->GetEffIndex();
|
||||
int32 heal = triggeredByAura->GetModifier()->m_amount;
|
||||
uint64 caster_guid = triggeredByAura->GetCasterGUID();
|
||||
ObjectGuid caster_guid = triggeredByAura->GetCasterGuid();
|
||||
|
||||
// jumps
|
||||
int32 jumps = triggeredByAura->GetHolder()->GetAuraCharges()-1;
|
||||
|
|
@ -3627,7 +3627,7 @@ SpellAuraProcResult Unit::HandleMendingAuraProc( Unit* /*pVictim*/, uint32 /*dam
|
|||
triggeredByAura->GetHolder()->SetAuraCharges(1); // will removed at next charges decrease
|
||||
|
||||
// next target selection
|
||||
if(jumps > 0 && GetTypeId()==TYPEID_PLAYER && IS_PLAYER_GUID(caster_guid))
|
||||
if (jumps > 0 && GetTypeId()==TYPEID_PLAYER && caster_guid.IsPlayer())
|
||||
{
|
||||
float radius;
|
||||
if (spellProto->EffectRadiusIndex[effIdx])
|
||||
|
|
@ -3691,7 +3691,7 @@ SpellAuraProcResult Unit::HandleMechanicImmuneResistanceAuraProc(Unit* /*pVictim
|
|||
SpellAuraProcResult Unit::HandleModDamageFromCasterAuraProc(Unit* pVictim, uint32 /*damage*/, Aura* triggeredByAura, SpellEntry const* /*procSpell*/, uint32 /*procFlag*/, uint32 /*procEx*/, uint32 /*cooldown*/)
|
||||
{
|
||||
// Compare casters
|
||||
return triggeredByAura->GetCasterGUID() == pVictim->GetGUID() ? SPELL_AURA_PROC_OK : SPELL_AURA_PROC_FAILED;
|
||||
return triggeredByAura->GetCasterGuid() == pVictim->GetObjectGuid() ? SPELL_AURA_PROC_OK : SPELL_AURA_PROC_FAILED;
|
||||
}
|
||||
|
||||
SpellAuraProcResult Unit::HandleMaelstromWeaponAuraProc(Unit* /*pVictim*/, uint32 /*damage*/, Aura* triggeredByAura, SpellEntry const* /*procSpell*/, uint32 /*procFlag*/, uint32 /*procEx*/, uint32 /*cooldown*/)
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "10746"
|
||||
#define REVISION_NR "10747"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue