*Implement SPELL_AURA_OPEN_STABLE(292) - original patch by Ceris, modified by VladimirMangos
*Improvements in error messaging for stable related opcodes - by VladimirMangos --HG-- branch : trunk
This commit is contained in:
@@ -336,7 +336,7 @@ enum AuraType
|
||||
SPELL_AURA_289 = 289,
|
||||
SPELL_AURA_MOD_CRIT_PCT = 290,
|
||||
SPELL_AURA_MOD_XP_QUEST_PCT = 291,
|
||||
SPELL_AURA_292 = 292,
|
||||
SPELL_AURA_OPEN_STABLE = 292,
|
||||
SPELL_AURA_293 = 293,
|
||||
SPELL_AURA_PREVENT_REGENERATE_POWER = 294,
|
||||
SPELL_AURA_295 = 295,
|
||||
|
||||
@@ -346,7 +346,7 @@ pAuraEffectHandler AuraEffectHandler[TOTAL_AURAS]=
|
||||
&AuraEffect::HandleNULL, //289 unused (3.2.0)
|
||||
&AuraEffect::HandleAuraModCritPct, //290 SPELL_AURA_MOD_CRIT_PCT
|
||||
&AuraEffect::HandleNoImmediateEffect, //291 SPELL_AURA_MOD_XP_QUEST_PCT implemented in Player::RewardQuest
|
||||
&AuraEffect::HandleNULL, //292 call stabled pet
|
||||
&AuraEffect::HandleAuraOpenStable, //292 SPELL_AURA_OPEN_STABLE
|
||||
&AuraEffect::HandleNULL, //293 auras which probably add set of abilities to their target based on it's miscvalue
|
||||
&AuraEffect::HandleNoImmediateEffect, //294 SPELL_AURA_PREVENT_REGENERATE_POWER implemented in Player::Regenerate(Powers power)
|
||||
&AuraEffect::HandleNULL, //295 0 spells in 3.3.5
|
||||
@@ -6256,3 +6256,19 @@ void AuraEffect::HandleAuraLinked(AuraApplication const * aurApp, uint8 mode, bo
|
||||
else
|
||||
target->RemoveAura(m_spellProto->EffectTriggerSpell[m_effIndex], GetCasterGUID(), 0, AuraRemoveMode(aurApp->GetRemoveMode()));
|
||||
}
|
||||
|
||||
void AuraEffect::HandleAuraOpenStable(AuraApplication const * aurApp, uint8 mode, bool apply) const
|
||||
{
|
||||
if (!(mode & AURA_EFFECT_HANDLE_REAL))
|
||||
return;
|
||||
|
||||
Unit * target = aurApp->GetTarget();
|
||||
|
||||
if (target->GetTypeId() != TYPEID_PLAYER || !target->IsInWorld())
|
||||
return;
|
||||
|
||||
if (apply)
|
||||
target->ToPlayer()->GetSession()->SendStablePet(target->GetGUID());
|
||||
|
||||
// client auto close stable dialog at !apply aura
|
||||
}
|
||||
|
||||
@@ -264,6 +264,7 @@ class AuraEffect
|
||||
void HandleComprehendLanguage(AuraApplication const * aurApp, uint8 mode, bool apply) const;
|
||||
void HandleAuraConvertRune(AuraApplication const * aurApp, uint8 mode, bool apply) const;
|
||||
void HandleAuraLinked(AuraApplication const * aurApp, uint8 mode, bool apply) const;
|
||||
void HandleAuraOpenStable(AuraApplication const * aurApp, uint8 mode, bool apply) const;
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user