mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-28 12:52:25 +01:00
*Remove stealth when unit gets hit
*Drop radius check for channeled auras, use range only. --HG-- branch : trunk
This commit is contained in:
@@ -24,4 +24,4 @@ INSERT INTO script_waypoint VALUES
|
||||
(12430, 1, 140.71, -4813.56, 17.04, 0, '');
|
||||
|
||||
UPDATE script_texts SET emote=20 WHERE entry=-1000231;
|
||||
UPDATE script_texts SET emote=4 WHERE entry IN (-1000232, -1000256, -1000258, -1000260, -1000262);
|
||||
UPDATE script_texts SET emote=4 WHERE entry IN (-1000232, -1000256, -1000258, -1000260, -1000262);
|
||||
|
||||
@@ -645,8 +645,7 @@ void Aura::Update(uint32 diff)
|
||||
|
||||
// Channeled aura required check distance from caster
|
||||
if(IsChanneledSpell(m_spellProto) && m_caster_guid != m_target->GetGUID()
|
||||
&& !IsAreaAura() && !IsPersistent() // check for these is done in auraeffect
|
||||
/* && !m_target->isPossessed()*/)
|
||||
&& !IsAreaAura() && !IsPersistent()) // check for these is done in auraeffect
|
||||
{
|
||||
Unit* caster = GetCaster();
|
||||
if(!caster)
|
||||
@@ -654,28 +653,10 @@ void Aura::Update(uint32 diff)
|
||||
m_target->RemoveAura(this);
|
||||
return;
|
||||
}
|
||||
// Get spell range
|
||||
float radius=-1.0f;
|
||||
SpellModOp mod;
|
||||
// get part aura with lowest radius
|
||||
for (uint8 i=0;i<3;++i)
|
||||
{
|
||||
if (HasEffect(i) && m_spellProto->EffectRadiusIndex[i])
|
||||
{
|
||||
float new_radius = caster->GetSpellRadiusForTarget(m_target, sSpellRadiusStore.LookupEntry(m_spellProto->EffectRadiusIndex[i]));
|
||||
if (radius < 0.0f || radius > new_radius)
|
||||
radius = new_radius;
|
||||
mod = SPELLMOD_RADIUS;
|
||||
}
|
||||
}
|
||||
if (radius < 0.0f)
|
||||
{
|
||||
radius = caster->GetSpellMaxRangeForTarget(m_target, sSpellRangeStore.LookupEntry(m_spellProto->rangeIndex)) ;
|
||||
mod = SPELLMOD_RANGE;
|
||||
}
|
||||
float radius = caster->GetSpellMaxRangeForTarget(m_target, sSpellRangeStore.LookupEntry(m_spellProto->rangeIndex)) ;
|
||||
|
||||
if(Player* modOwner = caster->GetSpellModOwner())
|
||||
modOwner->ApplySpellMod(GetId(), mod, radius,NULL);
|
||||
modOwner->ApplySpellMod(GetId(), SPELLMOD_RANGE, radius,NULL);
|
||||
|
||||
if(!caster->IsWithinDistInMap(m_target,radius))
|
||||
{
|
||||
|
||||
@@ -11487,6 +11487,7 @@ bool InitTriggerAuraData()
|
||||
isTriggerAura[SPELL_AURA_MOD_DAMAGE_DONE] = true;
|
||||
isTriggerAura[SPELL_AURA_MOD_DAMAGE_TAKEN] = true;
|
||||
isTriggerAura[SPELL_AURA_MOD_RESISTANCE] = true;
|
||||
isTriggerAura[SPELL_AURA_MOD_STEALTH] = true; // Aura not have charges but need remove him on trigger
|
||||
isTriggerAura[SPELL_AURA_MOD_ROOT] = true;
|
||||
isTriggerAura[SPELL_AURA_REFLECT_SPELLS] = true;
|
||||
isTriggerAura[SPELL_AURA_DAMAGE_IMMUNITY] = true;
|
||||
|
||||
Reference in New Issue
Block a user