mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 04:37:00 +00:00
[9525] Implement effect SPELL_EFFECT_TEACH_TAXI_NODE(154)
Original patch writed by Sadikum.
This commit is contained in:
parent
31f4850486
commit
acb297a415
4 changed files with 29 additions and 5 deletions
|
|
@ -682,7 +682,7 @@ enum SpellEffects
|
||||||
SPELL_EFFECT_TRIGGER_SPELL_2 = 151,
|
SPELL_EFFECT_TRIGGER_SPELL_2 = 151,
|
||||||
SPELL_EFFECT_152 = 152,
|
SPELL_EFFECT_152 = 152,
|
||||||
SPELL_EFFECT_153 = 153,
|
SPELL_EFFECT_153 = 153,
|
||||||
SPELL_EFFECT_154 = 154,
|
SPELL_EFFECT_TEACH_TAXI_NODE = 154,
|
||||||
SPELL_EFFECT_TITAN_GRIP = 155,
|
SPELL_EFFECT_TITAN_GRIP = 155,
|
||||||
SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC = 156,
|
SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC = 156,
|
||||||
SPELL_EFFECT_CREATE_ITEM_2 = 157,
|
SPELL_EFFECT_CREATE_ITEM_2 = 157,
|
||||||
|
|
|
||||||
|
|
@ -324,6 +324,7 @@ class Spell
|
||||||
void EffectKillCredit(SpellEffectIndex eff_idx);
|
void EffectKillCredit(SpellEffectIndex eff_idx);
|
||||||
void EffectQuestFail(SpellEffectIndex eff_idx);
|
void EffectQuestFail(SpellEffectIndex eff_idx);
|
||||||
void EffectActivateRune(SpellEffectIndex eff_idx);
|
void EffectActivateRune(SpellEffectIndex eff_idx);
|
||||||
|
void EffectTeachTaxiNode(SpellEffectIndex eff_idx);
|
||||||
void EffectTitanGrip(SpellEffectIndex eff_idx);
|
void EffectTitanGrip(SpellEffectIndex eff_idx);
|
||||||
void EffectEnchantItemPrismatic(SpellEffectIndex eff_idx);
|
void EffectEnchantItemPrismatic(SpellEffectIndex eff_idx);
|
||||||
void EffectPlayMusic(SpellEffectIndex eff_idx);
|
void EffectPlayMusic(SpellEffectIndex eff_idx);
|
||||||
|
|
|
||||||
|
|
@ -211,7 +211,7 @@ pEffect SpellEffects[TOTAL_SPELL_EFFECTS]=
|
||||||
&Spell::EffectTriggerRitualOfSummoning, //151 SPELL_EFFECT_TRIGGER_SPELL_2
|
&Spell::EffectTriggerRitualOfSummoning, //151 SPELL_EFFECT_TRIGGER_SPELL_2
|
||||||
&Spell::EffectNULL, //152 SPELL_EFFECT_152 summon Refer-a-Friend
|
&Spell::EffectNULL, //152 SPELL_EFFECT_152 summon Refer-a-Friend
|
||||||
&Spell::EffectNULL, //153 SPELL_EFFECT_CREATE_PET misc value is creature entry
|
&Spell::EffectNULL, //153 SPELL_EFFECT_CREATE_PET misc value is creature entry
|
||||||
&Spell::EffectNULL, //154 (single spell: Teach River's Heart Taxi Path)
|
&Spell::EffectTeachTaxiNode, //154 SPELL_EFFECT_TEACH_TAXI_NODE single spell: Teach River's Heart Taxi Path
|
||||||
&Spell::EffectTitanGrip, //155 SPELL_EFFECT_TITAN_GRIP Allows you to equip two-handed axes, maces and swords in one hand, but you attack $49152s1% slower than normal.
|
&Spell::EffectTitanGrip, //155 SPELL_EFFECT_TITAN_GRIP Allows you to equip two-handed axes, maces and swords in one hand, but you attack $49152s1% slower than normal.
|
||||||
&Spell::EffectEnchantItemPrismatic, //156 SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC
|
&Spell::EffectEnchantItemPrismatic, //156 SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC
|
||||||
&Spell::EffectCreateItem2, //157 SPELL_EFFECT_CREATE_ITEM_2 create item or create item template and replace by some randon spell loot item
|
&Spell::EffectCreateItem2, //157 SPELL_EFFECT_CREATE_ITEM_2 create item or create item template and replace by some randon spell loot item
|
||||||
|
|
@ -7471,7 +7471,7 @@ void Spell::EffectBind(SpellEffectIndex eff_idx)
|
||||||
|
|
||||||
void Spell::EffectRestoreItemCharges( SpellEffectIndex eff_idx )
|
void Spell::EffectRestoreItemCharges( SpellEffectIndex eff_idx )
|
||||||
{
|
{
|
||||||
if (m_caster->GetTypeId() != TYPEID_PLAYER)
|
if (unitTarget->GetTypeId() != TYPEID_PLAYER)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
Player* player = (Player*)unitTarget;
|
Player* player = (Player*)unitTarget;
|
||||||
|
|
@ -7492,3 +7492,26 @@ void Spell::EffectRestoreItemCharges( SpellEffectIndex eff_idx )
|
||||||
|
|
||||||
item->RestoreCharges();
|
item->RestoreCharges();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Spell::EffectTeachTaxiNode( SpellEffectIndex eff_idx )
|
||||||
|
{
|
||||||
|
if (unitTarget->GetTypeId() != TYPEID_PLAYER)
|
||||||
|
return;
|
||||||
|
|
||||||
|
Player* player = (Player*)unitTarget;
|
||||||
|
|
||||||
|
uint32 taxiNodeId = m_spellInfo->EffectMiscValue[eff_idx];
|
||||||
|
if (!sTaxiNodesStore.LookupEntry(taxiNodeId))
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (player->m_taxi.SetTaximaskNode(taxiNodeId))
|
||||||
|
{
|
||||||
|
WorldPacket data(SMSG_NEW_TAXI_PATH, 0);
|
||||||
|
player->SendDirectMessage( &data );
|
||||||
|
|
||||||
|
data.Initialize( SMSG_TAXINODE_STATUS, 9 );
|
||||||
|
data << uint64( m_caster->GetGUID() );
|
||||||
|
data << uint8( 1 );
|
||||||
|
player->SendDirectMessage( &data );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "9524"
|
#define REVISION_NR "9525"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue