*More cleanup of scripts.
--HG-- branch : trunk
This commit is contained in:
@@ -712,7 +712,7 @@ void LoadOverridenDBCData()
|
||||
SpellEntry *spellInfo;
|
||||
for(uint32 i = 0; i < GetSpellStore()->GetNumRows(); ++i)
|
||||
{
|
||||
spellInfo = (SpellEntry*)GetSpellStore()->LookupEntry(i);
|
||||
spellInfo = GET_SPELL(i);
|
||||
if(!spellInfo)
|
||||
continue;
|
||||
|
||||
|
||||
@@ -24,6 +24,8 @@
|
||||
#define CAST_AI(a,b) (static_cast<a*>(b))
|
||||
#endif
|
||||
|
||||
#define GET_SPELL(a) (const_cast<SpellEntry*>(GetSpellStore()->LookupEntry(a)))
|
||||
|
||||
class ScriptedInstance;
|
||||
|
||||
class SummonList : private std::list<uint64>
|
||||
@@ -68,10 +70,10 @@ struct TRINITY_DLL_DECL ScriptedAI : public CreatureAI
|
||||
void UpdateAI(const uint32);
|
||||
|
||||
//Called at creature death
|
||||
void JustDied(Unit*){}
|
||||
void JustDied(Unit* who){}
|
||||
|
||||
//Called at creature killing another unit
|
||||
void KilledUnit(Unit*){}
|
||||
void KilledUnit(Unit* who){}
|
||||
|
||||
// Called when the creature summon successfully other creature
|
||||
void JustSummoned(Creature* ) {}
|
||||
@@ -111,7 +113,7 @@ struct TRINITY_DLL_DECL ScriptedAI : public CreatureAI
|
||||
void Reset() {}
|
||||
|
||||
//Called at creature aggro either by MoveInLOS or Attack Start
|
||||
void EnterCombat(Unit*) {}
|
||||
void EnterCombat(Unit* who) {}
|
||||
|
||||
//*************
|
||||
//AI Helper Functions
|
||||
@@ -199,10 +201,10 @@ struct TRINITY_DLL_DECL Scripted_NoMovementAI : public ScriptedAI
|
||||
Scripted_NoMovementAI(Creature* creature) : ScriptedAI(creature) {}
|
||||
|
||||
//Called if IsVisible(Unit *who) is true at each *who move
|
||||
//void MoveInLineOfSight(Unit*);
|
||||
//void MoveInLineOfSight(Unit* who);
|
||||
|
||||
//Called at each attack of m_creature by any victim
|
||||
void AttackStart(Unit*);
|
||||
void AttackStart(Unit* who);
|
||||
};
|
||||
|
||||
struct TRINITY_DLL_DECL BossAI : public ScriptedAI
|
||||
|
||||
@@ -38,9 +38,9 @@ struct TRINITY_DLL_DECL npc_escortAI : public ScriptedAI
|
||||
npc_escortAI(Creature *c) : ScriptedAI(c), IsBeingEscorted(false), PlayerTimer(1000), MaxPlayerDistance(DEFAULT_MAX_PLAYER_DISTANCE), CanMelee(true), DespawnAtEnd(true), DespawnAtFar(true)
|
||||
{}
|
||||
|
||||
void AttackStart(Unit*);
|
||||
void AttackStart(Unit* who);
|
||||
|
||||
void MoveInLineOfSight(Unit*);
|
||||
void MoveInLineOfSight(Unit* who);
|
||||
|
||||
void JustRespawned();
|
||||
|
||||
|
||||
+1
-1
@@ -92,7 +92,7 @@ struct TRINITY_DLL_DECL mob_voidtravelerAI : public ScriptedAI
|
||||
{
|
||||
if(sacrificed)
|
||||
{
|
||||
SpellEntry *spell = (SpellEntry*)GetSpellStore()->LookupEntry(HeroicMode?H_SPELL_EMPOWERING_SHADOWS:SPELL_EMPOWERING_SHADOWS);
|
||||
SpellEntry *spell = GET_SPELL(HeroicMode?H_SPELL_EMPOWERING_SHADOWS:SPELL_EMPOWERING_SHADOWS);
|
||||
if( spell )
|
||||
Vorpil->AddAura(new Aura(spell, 1, NULL, Vorpil, m_creature));
|
||||
Vorpil->SetHealth(Vorpil->GetHealth()+Vorpil->GetMaxHealth()/25);
|
||||
|
||||
@@ -374,7 +374,7 @@ struct TRINITY_DLL_DECL mob_rizzle_sprysprocketAI : public ScriptedAI
|
||||
if (!who || PlayerGUID)
|
||||
return;
|
||||
|
||||
if(who->GetTypeId() == TYPEID_PLAYER && ((Player*)who)->GetQuestStatus(10994) == QUEST_STATUS_INCOMPLETE)
|
||||
if(who->GetTypeId() == TYPEID_PLAYER && CAST_PLR(who)->GetQuestStatus(10994) == QUEST_STATUS_INCOMPLETE)
|
||||
{
|
||||
PlayerGUID = who->GetGUID();
|
||||
DoScriptText(SAY_RIZZLE_START, m_creature);
|
||||
|
||||
@@ -369,7 +369,7 @@ struct TRINITY_DLL_DECL boss_illidan_stormrageAI : public ScriptedAI
|
||||
pInstance = (c->GetInstanceData());
|
||||
m_creature->CastSpell(m_creature, SPELL_DUAL_WIELD, true);
|
||||
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_SHADOWFIEND_PASSIVE);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_SHADOWFIEND_PASSIVE);
|
||||
if(TempSpell)
|
||||
TempSpell->EffectApplyAuraName[0] = 4; // proc debuff, and summon infinite fiends
|
||||
}
|
||||
@@ -1045,7 +1045,7 @@ struct TRINITY_DLL_DECL npc_akama_illidanAI : public ScriptedAI
|
||||
}
|
||||
|
||||
void EnterCombat(Unit *who) {}
|
||||
void MoveInLineOfSight(Unit*) {}
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
|
||||
void MovementInform(uint32 MovementType, uint32 Data) {Timer = 1;}
|
||||
|
||||
|
||||
@@ -223,7 +223,7 @@ void SendDefaultMenu_boss_vael(Player *player, Creature *_Creature, uint32 actio
|
||||
if (action == GOSSIP_ACTION_INFO_DEF + 1) //Fight time
|
||||
{
|
||||
player->CLOSE_GOSSIP_MENU();
|
||||
CAST_AI(boss_vaelAI, _Creature->AI())->BeginSpeach((Unit*)player);
|
||||
CAST_AI(boss_vaelAI, _Creature->AI())->BeginSpeach(player);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ struct TRINITY_DLL_DECL boss_anetheronAI : public hyjal_trashAI
|
||||
pInstance = (c->GetInstanceData());
|
||||
go = false;
|
||||
pos = 0;
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_SLEEP);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_SLEEP);
|
||||
if(TempSpell && TempSpell->EffectImplicitTargetA[0] != 1)
|
||||
{
|
||||
TempSpell->EffectImplicitTargetA[0] = 1;
|
||||
|
||||
@@ -34,7 +34,7 @@ struct TRINITY_DLL_DECL boss_azgalorAI : public hyjal_trashAI
|
||||
pInstance = (c->GetInstanceData());
|
||||
go = false;
|
||||
pos = 0;
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_HOWL_OF_AZGALOR);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_HOWL_OF_AZGALOR);
|
||||
if(TempSpell)
|
||||
TempSpell->EffectRadiusIndex[0] = 12;//100yards instead of 50000?!
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ struct TRINITY_DLL_DECL boss_kazrogalAI : public hyjal_trashAI
|
||||
pInstance = (c->GetInstanceData());
|
||||
go = false;
|
||||
pos = 0;
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_MARK);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_MARK);
|
||||
if(TempSpell && TempSpell->EffectImplicitTargetA[0] != 1)
|
||||
{
|
||||
TempSpell->EffectImplicitTargetA[0] = 1;
|
||||
|
||||
@@ -66,7 +66,7 @@ CreatureAI* GetAI_npc_jaina_proudmoore(Creature *_Creature)
|
||||
|
||||
bool GossipHello_npc_jaina_proudmoore(Player *player, Creature *_Creature)
|
||||
{
|
||||
hyjalAI* ai = ((hyjalAI*)_Creature->AI());
|
||||
hyjalAI* ai = CAST_AI(hyjalAI, _Creature->AI());
|
||||
if(ai->EventBegun)
|
||||
return false;
|
||||
|
||||
@@ -88,7 +88,7 @@ bool GossipHello_npc_jaina_proudmoore(Player *player, Creature *_Creature)
|
||||
|
||||
bool GossipSelect_npc_jaina_proudmoore(Player *player, Creature *_Creature, uint32 sender, uint32 action)
|
||||
{
|
||||
hyjalAI* ai = ((hyjalAI*)_Creature->AI());
|
||||
hyjalAI* ai = CAST_AI(hyjalAI, _Creature->AI());
|
||||
switch(action)
|
||||
{
|
||||
case GOSSIP_ACTION_INFO_DEF + 1:
|
||||
@@ -130,7 +130,7 @@ CreatureAI* GetAI_npc_thrall(Creature *_Creature)
|
||||
|
||||
bool GossipHello_npc_thrall(Player *player, Creature *_Creature)
|
||||
{
|
||||
hyjalAI* ai = ((hyjalAI*)_Creature->AI());
|
||||
hyjalAI* ai = CAST_AI(hyjalAI, _Creature->AI());
|
||||
if (ai->EventBegun)
|
||||
return false;
|
||||
|
||||
@@ -157,7 +157,7 @@ bool GossipHello_npc_thrall(Player *player, Creature *_Creature)
|
||||
|
||||
bool GossipSelect_npc_thrall(Player *player, Creature *_Creature, uint32 sender, uint32 action)
|
||||
{
|
||||
hyjalAI* ai = ((hyjalAI*)_Creature->AI());
|
||||
hyjalAI* ai = CAST_AI(hyjalAI, _Creature->AI());
|
||||
ai->DeSpawnVeins();//despawn the alliance veins
|
||||
switch(action)
|
||||
{
|
||||
@@ -190,7 +190,7 @@ CreatureAI* GetAI_npc_tyrande_whisperwind(Creature *_Creature)
|
||||
|
||||
bool GossipHello_npc_tyrande_whisperwind(Player* player, Creature* _Creature)
|
||||
{
|
||||
hyjalAI* ai = ((hyjalAI*)_Creature->AI());
|
||||
hyjalAI* ai = CAST_AI(hyjalAI, _Creature->AI());
|
||||
uint32 AzgalorEvent = ai->GetInstanceData(DATA_AZGALOREVENT);
|
||||
|
||||
// Only let them get item if Azgalor is dead.
|
||||
@@ -213,7 +213,7 @@ bool GossipSelect_npc_tyrande_whisperwind(Player *player, Creature *_Creature, u
|
||||
player->SendNewItem(item,1,true,false,true);
|
||||
}
|
||||
player->SEND_GOSSIP_MENU(907, _Creature->GetGUID());
|
||||
hyjalAI* ai = ((hyjalAI*)_Creature->AI());
|
||||
hyjalAI* ai = CAST_AI(hyjalAI, _Creature->AI());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -728,7 +728,7 @@ void hyjalAI::DeSpawnVeins()
|
||||
{
|
||||
Creature* pUnit=Unit::GetCreature((*m_creature),pInstance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (!pUnit)return;
|
||||
hyjalAI* ai = ((hyjalAI*)pUnit->AI());
|
||||
hyjalAI* ai = CAST_AI(hyjalAI, pUnit->AI());
|
||||
if(!ai)return;
|
||||
for (uint8 i = 0; i<7; i++)
|
||||
{
|
||||
@@ -740,7 +740,7 @@ void hyjalAI::DeSpawnVeins()
|
||||
{
|
||||
Creature* pUnit=Unit::GetCreature((*m_creature),pInstance->GetData64(DATA_THRALL));
|
||||
if (!pUnit)return;
|
||||
hyjalAI* ai = ((hyjalAI*)pUnit->AI());
|
||||
hyjalAI* ai = CAST_AI(hyjalAI, pUnit->AI());
|
||||
if(!ai)return;
|
||||
for (uint8 i = 7; i<14; i++)
|
||||
{
|
||||
|
||||
@@ -1346,7 +1346,7 @@ struct TRINITY_DLL_DECL alliance_riflemanAI : public Scripted_NoMovementAI
|
||||
|
||||
uint32 ExplodeTimer;
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -657,7 +657,7 @@ struct TRINITY_DLL_DECL mob_enchanted_elementalAI : public ScriptedAI
|
||||
m_creature->GetMotionMaster()->MovePoint(0, MIDDLE_X, MIDDLE_Y, MIDDLE_Z);
|
||||
if(m_creature->GetDistance(MIDDLE_X, MIDDLE_Y, MIDDLE_Z) < 3)
|
||||
{
|
||||
SpellEntry *spell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_SURGE);
|
||||
SpellEntry *spell = GET_SPELL(SPELL_SURGE);
|
||||
if( spell )
|
||||
{
|
||||
uint8 eff_mask=0;
|
||||
|
||||
+8
-8
@@ -326,10 +326,10 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
|
||||
{
|
||||
if(InnderDemon[i] > 0 )
|
||||
{
|
||||
Unit* pUnit = Unit::GetUnit((*m_creature), InnderDemon[i]);
|
||||
Creature* pUnit = Unit::GetCreature((*m_creature), InnderDemon[i]);
|
||||
if (pUnit && pUnit->isAlive())
|
||||
{
|
||||
Unit* pUnit_target = Unit::GetUnit((*pUnit), ((mob_inner_demonAI*)((Creature*)pUnit)->AI())->victimGUID);
|
||||
Unit* pUnit_target = Unit::GetUnit(*pUnit, CAST_AI(mob_inner_demonAI, pUnit->AI())->victimGUID);
|
||||
if( pUnit_target && pUnit_target->isAlive())
|
||||
{
|
||||
pUnit->CastSpell(pUnit_target, SPELL_CONSUMING_MADNESS, true);
|
||||
@@ -496,16 +496,16 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
|
||||
if(tempTarget && tempTarget->GetTypeId() == TYPEID_PLAYER && tempTarget->GetGUID() != m_creature->getVictim()->GetGUID() && TargetList.size()<5)
|
||||
TargetList.push_back( tempTarget );
|
||||
}
|
||||
SpellEntry *spell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_INSIDIOUS_WHISPER);
|
||||
SpellEntry *spell = GET_SPELL(SPELL_INSIDIOUS_WHISPER);
|
||||
for(std::vector<Unit *>::iterator itr = TargetList.begin(); itr != TargetList.end(); ++itr)
|
||||
{
|
||||
if( (*itr) && (*itr)->isAlive() )
|
||||
{
|
||||
Creature * demon = (Creature*)m_creature->SummonCreature(INNER_DEMON_ID, (*itr)->GetPositionX()+10, (*itr)->GetPositionY()+10, (*itr)->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
|
||||
Creature * demon = m_creature->SummonCreature(INNER_DEMON_ID, (*itr)->GetPositionX()+10, (*itr)->GetPositionY()+10, (*itr)->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
|
||||
if(demon)
|
||||
{
|
||||
((ScriptedAI*)demon->AI())->AttackStart( (*itr) );
|
||||
((mob_inner_demonAI*)demon->AI())->victimGUID = (*itr)->GetGUID();
|
||||
demon->AI()->AttackStart( (*itr) );
|
||||
CAST_AI(mob_inner_demonAI, demon->AI())->victimGUID = (*itr)->GetGUID();
|
||||
|
||||
uint8 eff_mask=0;
|
||||
for (int i=0; i<3; i++)
|
||||
@@ -662,7 +662,7 @@ struct TRINITY_DLL_DECL mob_greyheart_spellbinderAI : public ScriptedAI
|
||||
if(pInstance)
|
||||
{
|
||||
pInstance->SetData64(DATA_LEOTHERAS_EVENT_STARTER, 0);
|
||||
Creature *leotheras = (Creature*)Unit::GetUnit(*m_creature, leotherasGUID);
|
||||
Creature *leotheras = Unit::GetCreature(*m_creature, leotherasGUID);
|
||||
if(leotheras && leotheras->isAlive())
|
||||
CAST_AI(boss_leotheras_the_blindAI, leotheras->AI())->CheckChannelers(false);
|
||||
}
|
||||
@@ -687,7 +687,7 @@ struct TRINITY_DLL_DECL mob_greyheart_spellbinderAI : public ScriptedAI
|
||||
{
|
||||
if(leotherasGUID)
|
||||
{
|
||||
Creature *leotheras = (Creature*)Unit::GetUnit(*m_creature, leotherasGUID);
|
||||
Creature *leotheras = Unit::GetCreature(*m_creature, leotherasGUID);
|
||||
if(leotheras && leotheras->isAlive())
|
||||
DoCast(leotheras, BANISH_BEAM);
|
||||
}
|
||||
|
||||
+2
-2
@@ -77,7 +77,7 @@ struct TRINITY_DLL_DECL boss_the_lurker_belowAI : public Scripted_NoMovementAI
|
||||
boss_the_lurker_belowAI(Creature *c) : Scripted_NoMovementAI(c), Summons(m_creature)
|
||||
{
|
||||
pInstance = (c->GetInstanceData());
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_SPOUT_ANIM);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_SPOUT_ANIM);
|
||||
if(TempSpell)
|
||||
{
|
||||
TempSpell->Effect[0] = 0;//remove all spell effect, only anim is needed
|
||||
@@ -403,7 +403,7 @@ struct TRINITY_DLL_DECL mob_coilfang_ambusherAI : public Scripted_NoMovementAI
|
||||
{
|
||||
mob_coilfang_ambusherAI(Creature *c) : Scripted_NoMovementAI(c)
|
||||
{
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_SHOOT);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_SHOOT);
|
||||
if(TempSpell)
|
||||
TempSpell->Effect[0] = 2;//change spell effect from weapon % dmg to simple phisical dmg
|
||||
}
|
||||
|
||||
+1
-1
@@ -119,7 +119,7 @@ struct TRINITY_DLL_DECL boss_the_black_stalkerAI : public ScriptedAI
|
||||
{
|
||||
if(LevitatedTarget_Timer < diff)
|
||||
{
|
||||
if(Unit* target = (Unit*)Unit::GetUnit(*m_creature, LevitatedTarget))
|
||||
if(Unit* target = Unit::GetUnit(*m_creature, LevitatedTarget))
|
||||
{
|
||||
if(!target->HasAura(SPELL_LEVITATE))
|
||||
{
|
||||
|
||||
+1
-1
@@ -226,7 +226,7 @@ struct TRINITY_DLL_DECL boss_kelidan_the_breakerAI : public ScriptedAI
|
||||
|
||||
DoScriptText(SAY_NOVA, m_creature);
|
||||
|
||||
if(SpellEntry *nova = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_BURNING_NOVA))
|
||||
if(SpellEntry *nova = GET_SPELL(SPELL_BURNING_NOVA))
|
||||
{
|
||||
uint8 eff_mask=0;
|
||||
for (int i=0; i<3; i++)
|
||||
|
||||
+2
-2
@@ -335,7 +335,7 @@ struct TRINITY_DLL_DECL boss_vazruden_the_heraldAI : public ScriptedAI
|
||||
Unit *victim = m_creature->getVictim();
|
||||
if(summoned->GetEntry() == ENTRY_NAZAN)
|
||||
{
|
||||
((boss_nazanAI*)summoned->AI())->VazrudenGUID = VazrudenGUID;
|
||||
CAST_AI(boss_nazanAI, summoned->AI())->VazrudenGUID = VazrudenGUID;
|
||||
summoned->AddUnitMovementFlag(MOVEMENTFLAG_LEVITATING);
|
||||
summoned->SetSpeed(MOVE_FLIGHT, 2.5);
|
||||
if(victim)
|
||||
@@ -424,7 +424,7 @@ struct TRINITY_DLL_DECL mob_hellfire_sentryAI : public ScriptedAI
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
if(Creature *herald = me->FindNearestCreature(ENTRY_VAZRUDEN_HERALD,150))
|
||||
((boss_vazruden_the_heraldAI*)herald->AI())->SentryDownBy(who);
|
||||
CAST_AI(boss_vazruden_the_heraldAI, herald->AI())->SentryDownBy(who);
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
|
||||
+6
-6
@@ -128,7 +128,7 @@ struct TRINITY_DLL_DECL mob_abyssalAI : public ScriptedAI
|
||||
}
|
||||
}
|
||||
|
||||
void EnterCombat(Unit*) {DoZoneInCombat();}
|
||||
void EnterCombat(Unit* who) {DoZoneInCombat();}
|
||||
void AttackStart(Unit *who) {if(!trigger) ScriptedAI::AttackStart(who);}
|
||||
void MoveInLineOfSight(Unit *who) {if(!trigger) ScriptedAI::MoveInLineOfSight(who);}
|
||||
|
||||
@@ -176,13 +176,13 @@ struct TRINITY_DLL_DECL boss_magtheridonAI : public ScriptedAI
|
||||
|
||||
// target 7, random target with certain entry spell, need core fix
|
||||
SpellEntry *TempSpell;
|
||||
TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_BLAZE_TARGET);
|
||||
TempSpell = GET_SPELL(SPELL_BLAZE_TARGET);
|
||||
if(TempSpell && TempSpell->EffectImplicitTargetA[0] != 6)
|
||||
{
|
||||
TempSpell->EffectImplicitTargetA[0] = 6;
|
||||
TempSpell->EffectImplicitTargetB[0] = 0;
|
||||
}
|
||||
TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_QUAKE_TRIGGER);
|
||||
TempSpell = GET_SPELL(SPELL_QUAKE_TRIGGER);
|
||||
if(TempSpell && TempSpell->EffectTriggerSpell[0] != SPELL_QUAKE_KNOCKBACK)
|
||||
{
|
||||
TempSpell->EffectTriggerSpell[0] = SPELL_QUAKE_KNOCKBACK;
|
||||
@@ -289,7 +289,7 @@ struct TRINITY_DLL_DECL boss_magtheridonAI : public ScriptedAI
|
||||
DoScriptText(SAY_DEATH, m_creature);
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit*) {}
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
|
||||
void AttackStart(Unit *who)
|
||||
{
|
||||
@@ -450,7 +450,7 @@ struct TRINITY_DLL_DECL mob_hellfire_channelerAI : public ScriptedAI
|
||||
|
||||
void JustSummoned(Creature *summon) {summon->AI()->AttackStart(m_creature->getVictim());}
|
||||
|
||||
void MoveInLineOfSight(Unit*) {}
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
|
||||
void DamageTaken(Unit*, uint32 &damage)
|
||||
{
|
||||
@@ -458,7 +458,7 @@ struct TRINITY_DLL_DECL mob_hellfire_channelerAI : public ScriptedAI
|
||||
m_creature->CastSpell(m_creature, SPELL_SOUL_TRANSFER, true);
|
||||
}
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
if(pInstance)
|
||||
pInstance->SetData(DATA_CHANNELER_EVENT, DONE);
|
||||
|
||||
@@ -586,7 +586,7 @@ struct TRINITY_DLL_DECL mob_sparrowhawkAI : public ScriptedAI
|
||||
if(!who || PlayerGUID)
|
||||
return;
|
||||
|
||||
if(!PlayerGUID && who->GetTypeId() == TYPEID_PLAYER && m_creature->IsWithinDistInMap(((Player*)who), 30) && ((Player*)who)->GetQuestStatus(10987) == QUEST_STATUS_INCOMPLETE)
|
||||
if(!PlayerGUID && who->GetTypeId() == TYPEID_PLAYER && m_creature->IsWithinDistInMap(who, 30) && CAST_PLR(who)->GetQuestStatus(10987) == QUEST_STATUS_INCOMPLETE)
|
||||
{
|
||||
PlayerGUID = who->GetGUID();
|
||||
return;
|
||||
|
||||
@@ -121,7 +121,7 @@ struct TRINITY_DLL_DECL boss_sapphironAI : public BossAI
|
||||
}
|
||||
}
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
_JustDied();
|
||||
me->CastSpell(me, SPELL_DIES, true);
|
||||
|
||||
@@ -134,10 +134,10 @@ struct TRINITY_DLL_DECL mob_wisp_invisAI : public ScriptedAI
|
||||
{
|
||||
Creaturetype = delay = spell = spell2 = 0;
|
||||
//that's hack but there are no info about range of this spells in dbc
|
||||
SpellEntry *wisp = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_WISP_BLUE);
|
||||
SpellEntry *wisp = GET_SPELL(SPELL_WISP_BLUE);
|
||||
if (wisp)
|
||||
wisp->rangeIndex = 6; //100 yards
|
||||
SpellEntry *port = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_WISP_FLIGHT_PORT);
|
||||
SpellEntry *port = GET_SPELL(SPELL_WISP_FLIGHT_PORT);
|
||||
if (port)
|
||||
port->rangeIndex = 6;
|
||||
}
|
||||
@@ -321,7 +321,7 @@ struct TRINITY_DLL_DECL boss_headless_horsemanAI : public ScriptedAI
|
||||
{
|
||||
boss_headless_horsemanAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
SpellEntry *confl = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_CONFLAGRATION);
|
||||
SpellEntry *confl = GET_SPELL(SPELL_CONFLAGRATION);
|
||||
if(confl)
|
||||
{
|
||||
confl->EffectApplyAuraName[0] = SPELL_AURA_PERIODIC_DAMAGE_PERCENT;
|
||||
@@ -329,11 +329,11 @@ struct TRINITY_DLL_DECL boss_headless_horsemanAI : public ScriptedAI
|
||||
confl->EffectBaseDice[0] = 10;
|
||||
confl->DmgMultiplier[0] = 1;
|
||||
}
|
||||
/* SpellEntry *confl = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_CONFLAGRATION);
|
||||
/* SpellEntry *confl = GET_SPELL(SPELL_CONFLAGRATION);
|
||||
if(confl)
|
||||
confl->EffectTriggerSpell[1] = 22587;
|
||||
|
||||
SpellEntry *speed = (SpellEntry*)GetSpellStore()->LookupEntry(22587);
|
||||
SpellEntry *speed = GET_SPELL(22587);
|
||||
if(speed)
|
||||
{
|
||||
speed->Effect[1] = SPELL_EFFECT_APPLY_AURA;
|
||||
@@ -635,7 +635,7 @@ struct TRINITY_DLL_DECL boss_headless_horsemanAI : public ScriptedAI
|
||||
case 2:
|
||||
if (conflagrate < diff)
|
||||
{
|
||||
Unit *plr = (Unit*)SelectRandomPlayer(30.0f);
|
||||
Unit *plr = SelectRandomPlayer(30.0f);
|
||||
if (plr)
|
||||
m_creature->CastSpell(plr,SPELL_CONFLAGRATION,false);
|
||||
conflagrate = 10000 + rand()%7 * 1000;
|
||||
|
||||
@@ -1381,8 +1381,9 @@ struct TRINITY_DLL_DECL mob_torloth_the_magnificentAI : public ScriptedAI
|
||||
switch(slayer->GetTypeId())
|
||||
{
|
||||
case TYPEID_UNIT:
|
||||
if(CAST_CRE(slayer)->isPet() && ((Pet*)slayer)->GetOwner()->GetTypeId() == TYPEID_PLAYER)
|
||||
CAST_PLR(((Pet*)slayer->GetOwner()))->GroupEventHappens(QUEST_BATTLE_OF_THE_CRIMSON_WATCH, m_creature);
|
||||
if(Unit *owner = slayer->GetOwner())
|
||||
if(owner->GetTypeId() == TYPEID_PLAYER)
|
||||
CAST_PLR(owner)->GroupEventHappens(QUEST_BATTLE_OF_THE_CRIMSON_WATCH, m_creature);
|
||||
break;
|
||||
|
||||
case TYPEID_PLAYER:
|
||||
@@ -1742,10 +1743,10 @@ struct TRINITY_DLL_DECL npc_enraged_spiritAI : public ScriptedAI
|
||||
Summoned->setFaction(ENRAGED_SOUL_FRIENDLY);
|
||||
Summoned->GetMotionMaster()->MovePoint(0,totemOspirits->GetPositionX(), totemOspirits->GetPositionY(), Summoned->GetPositionZ());
|
||||
|
||||
Player* Owner = (Player*)totemOspirits->GetOwner();
|
||||
if (Owner)
|
||||
Unit* Owner = totemOspirits->GetOwner();
|
||||
if (Owner && Owner->GetTypeId() == TYPEID_PLAYER)
|
||||
// DoCast(Owner, credit); -- not working!
|
||||
Owner->KilledMonster(credit, Summoned->GetGUID());
|
||||
CAST_PLR(Owner)->KilledMonster(credit, Summoned->GetGUID());
|
||||
DoCast(totemOspirits,SPELL_SOUL_CAPTURED);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -533,7 +533,7 @@ struct TRINITY_DLL_DECL boss_alythessAI : public Scripted_NoMovementAI
|
||||
|
||||
uint32 IntroStep(uint32 step)
|
||||
{
|
||||
Creature* Sacrolash = (Creature*)Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_SACROLASH));
|
||||
Creature* Sacrolash = Unit::GetCreature((*m_creature),pInstance->GetData64(DATA_SACROLASH));
|
||||
switch (step)
|
||||
{
|
||||
case 0: return 0;
|
||||
|
||||
@@ -130,13 +130,13 @@ struct TRINITY_DLL_DECL boss_felmystAI : public ScriptedAI
|
||||
pInstance = (c->GetInstanceData());
|
||||
|
||||
// wait for core patch be accepted
|
||||
/*SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_ENCAPSULATE_EFFECT);
|
||||
/*SpellEntry *TempSpell = GET_SPELL(SPELL_ENCAPSULATE_EFFECT);
|
||||
if(TempSpell->SpellIconID == 2294)
|
||||
TempSpell->SpellIconID = 2295;
|
||||
TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_VAPOR_TRIGGER);
|
||||
TempSpell = GET_SPELL(SPELL_VAPOR_TRIGGER);
|
||||
if((TempSpell->Attributes & SPELL_ATTR_PASSIVE) == 0)
|
||||
TempSpell->Attributes |= SPELL_ATTR_PASSIVE;
|
||||
TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_FOG_CHARM2);
|
||||
TempSpell = GET_SPELL(SPELL_FOG_CHARM2);
|
||||
if((TempSpell->Attributes & SPELL_ATTR_PASSIVE) == 0)
|
||||
TempSpell->Attributes |= SPELL_ATTR_PASSIVE;*/
|
||||
}
|
||||
|
||||
@@ -704,7 +704,7 @@ struct TRINITY_DLL_DECL boss_kiljaedenAI : public Scripted_NoMovementAI
|
||||
if(Phase <= PHASE_ARMAGEDDON){
|
||||
if(Phase == PHASE_ARMAGEDDON && ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 25)){
|
||||
Phase = PHASE_SACRIFICE;
|
||||
Creature* Anveena = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_ANVEENA)));
|
||||
Creature* Anveena = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_ANVEENA)));
|
||||
if (Anveena)Anveena->CastSpell(m_creature, SPELL_SACRIFICE_OF_ANVEENA, false);
|
||||
OrbActivated = false;
|
||||
ChangeTimers(true, 10000);// He shouldn't cast spells for ~10 seconds after Anveena's sacrifice. This will be done within Anveena's script
|
||||
|
||||
@@ -362,8 +362,7 @@ struct TRINITY_DLL_DECL npc_muru_portalAI : public Scripted_NoMovementAI
|
||||
}
|
||||
|
||||
void JustSummoned(Creature* summoned){
|
||||
Player* Target;
|
||||
Target = (Player*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_PLAYER_GUID)));
|
||||
Player* Target = Unit::GetPlayer(pInstance->GetData64(DATA_PLAYER_GUID));
|
||||
if(Target)summoned->AI()->AttackStart(Target);
|
||||
Summons.Summon(summoned);
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ struct TRINITY_DLL_DECL mob_treantAI : public ScriptedAI
|
||||
|
||||
void EnterCombat(Unit *who) {}
|
||||
|
||||
void MoveInLineOfSight(Unit*) {}
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
{
|
||||
@@ -54,7 +54,7 @@ struct TRINITY_DLL_DECL mob_treantAI : public ScriptedAI
|
||||
{
|
||||
if(WarpGuid && check_Timer < diff)
|
||||
{
|
||||
if(Unit *Warp = (Unit*)Unit::GetUnit(*m_creature, WarpGuid))
|
||||
if(Unit *Warp = Unit::GetUnit(*m_creature, WarpGuid))
|
||||
{
|
||||
if(m_creature->IsWithinMeleeRange(Warp,2.5f))
|
||||
{
|
||||
|
||||
@@ -734,7 +734,7 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
|
||||
if (!Advisor)
|
||||
error_log("TSCR: Kael'Thas Advisor %u does not exist. Possibly despawned? Incorrectly Killed?", i);
|
||||
else if(Target)
|
||||
((advisorbase_ai*)Advisor->AI())->Revive(Target);
|
||||
CAST_AI(advisorbase_ai, Advisor->AI())->Revive(Target);
|
||||
}
|
||||
|
||||
PhaseSubphase = 1;
|
||||
|
||||
@@ -925,7 +925,7 @@ struct TRINITY_DLL_DECL eye_tentacleAI : public Scripted_NoMovementAI
|
||||
uint32 KillSelfTimer;
|
||||
uint64 Portal;
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
Unit* p = Unit::GetUnit(*m_creature, Portal);
|
||||
if (p)
|
||||
@@ -988,7 +988,7 @@ struct TRINITY_DLL_DECL claw_tentacleAI : public Scripted_NoMovementAI
|
||||
uint32 EvadeTimer;
|
||||
uint64 Portal;
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
Unit* p = Unit::GetUnit(*m_creature, Portal);
|
||||
if (p)
|
||||
@@ -1083,7 +1083,7 @@ struct TRINITY_DLL_DECL giant_claw_tentacleAI : public Scripted_NoMovementAI
|
||||
uint32 EvadeTimer;
|
||||
uint64 Portal;
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
Unit* p = Unit::GetUnit(*m_creature, Portal);
|
||||
if (p)
|
||||
@@ -1184,7 +1184,7 @@ struct TRINITY_DLL_DECL giant_eye_tentacleAI : public Scripted_NoMovementAI
|
||||
uint32 BeamTimer;
|
||||
uint64 Portal;
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
Unit* p = Unit::GetUnit(*m_creature, Portal);
|
||||
if (p)
|
||||
|
||||
@@ -243,7 +243,7 @@ struct TRINITY_DLL_DECL boss_skeramAI : public ScriptedAI
|
||||
Unit *targetpl = SelectUnit(SELECT_TARGET_RANDOM, 0);
|
||||
if (targetpl->GetTypeId() == TYPEID_PLAYER)
|
||||
{
|
||||
Group *grp = ((Player*)targetpl)->GetGroup();
|
||||
Group *grp = CAST_PLR(targetpl)->GetGroup();
|
||||
if (grp)
|
||||
{
|
||||
for (int ici = 0; ici < TARGETICONCOUNT; ici++)
|
||||
|
||||
@@ -148,7 +148,7 @@ struct TRINITY_DLL_DECL boss_twinemperorsAI : public ScriptedAI
|
||||
{
|
||||
// TODO: we should activate the other boss location so he can start attackning even if nobody
|
||||
// is near I dont know how to do that
|
||||
ScriptedAI *otherAI = (ScriptedAI*)pOtherBoss->AI();
|
||||
ScriptedAI *otherAI = CAST_AI(ScriptedAI, pOtherBoss->AI());
|
||||
if (!pOtherBoss->isInCombat())
|
||||
{
|
||||
DoPlaySoundToSet(m_creature, IAmVeklor() ? SOUND_VL_AGGRO : SOUND_VN_AGGRO);
|
||||
@@ -197,7 +197,7 @@ struct TRINITY_DLL_DECL boss_twinemperorsAI : public ScriptedAI
|
||||
if (Heal_Timer < diff)
|
||||
{
|
||||
Unit *pOtherBoss = GetOtherBoss();
|
||||
if (pOtherBoss && (pOtherBoss->GetDistance((const Creature*)m_creature) <= 60))
|
||||
if (pOtherBoss && (pOtherBoss->GetDistance(m_creature) <= 60))
|
||||
{
|
||||
DoCast(pOtherBoss, SPELL_HEAL_BROTHER);
|
||||
Heal_Timer = 1000;
|
||||
@@ -316,9 +316,9 @@ struct TRINITY_DLL_DECL boss_twinemperorsAI : public ScriptedAI
|
||||
{
|
||||
public:
|
||||
AnyBugCheck(WorldObject const* obj, float range) : i_obj(obj), i_range(range) {}
|
||||
bool operator()(Unit* u)
|
||||
bool operator()(Creature* u)
|
||||
{
|
||||
Creature *c = (Creature*)u;
|
||||
Creature *c = u;
|
||||
if (!i_obj->IsWithinDistInMap(c, i_range))
|
||||
return false;
|
||||
return (c->GetEntry() == 15316 || c->GetEntry() == 15317);
|
||||
@@ -347,7 +347,7 @@ struct TRINITY_DLL_DECL boss_twinemperorsAI : public ScriptedAI
|
||||
|
||||
for(std::list<Creature*>::iterator iter = unitList.begin(); iter != unitList.end(); ++iter)
|
||||
{
|
||||
Creature *c = (Creature*)(*iter);
|
||||
Creature *c = *iter;
|
||||
if (c && c->isDead())
|
||||
{
|
||||
c->Respawn();
|
||||
@@ -435,7 +435,7 @@ struct TRINITY_DLL_DECL boss_veknilashAI : public boss_twinemperorsAI
|
||||
{
|
||||
target->setFaction(14);
|
||||
(target->AI())->AttackStart(m_creature->getThreatManager().getHostilTarget());
|
||||
SpellEntry *spell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_MUTATE_BUG);
|
||||
SpellEntry *spell = GET_SPELL(SPELL_MUTATE_BUG);
|
||||
uint8 eff_mask=0;
|
||||
for (int i=0; i<3; i++)
|
||||
{
|
||||
@@ -520,7 +520,7 @@ struct TRINITY_DLL_DECL boss_veklorAI : public boss_twinemperorsAI
|
||||
void CastSpellOnBug(Creature *target)
|
||||
{
|
||||
target->setFaction(14);
|
||||
SpellEntry *spell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_EXPLODEBUG);
|
||||
SpellEntry *spell = GET_SPELL(SPELL_EXPLODEBUG);
|
||||
uint8 eff_mask=0;
|
||||
for (int i=0; i<3; i++)
|
||||
{
|
||||
|
||||
@@ -133,7 +133,7 @@ struct TRINITY_DLL_DECL aqsentinelAI : public ScriptedAI
|
||||
|
||||
void GiveBuddyMyList(Creature *c)
|
||||
{
|
||||
aqsentinelAI *cai = (aqsentinelAI*)(c->AI());
|
||||
aqsentinelAI *cai = CAST_AI(aqsentinelAI, (c)->AI());
|
||||
for (int i=0; i<3; i++)
|
||||
if (nearby[i] && nearby[i]!=c)
|
||||
cai->AddBuddyToList(nearby[i]);
|
||||
@@ -213,8 +213,8 @@ struct TRINITY_DLL_DECL aqsentinelAI : public ScriptedAI
|
||||
if (!nearby[bli])
|
||||
break;
|
||||
AddSentinelsNear(nearby[bli]);
|
||||
((aqsentinelAI*)nearby[bli]->AI())->gatherOthersWhenAggro = false;
|
||||
((aqsentinelAI*)nearby[bli]->AI())->selectAbility(pickAbilityRandom(chosenAbilities));
|
||||
CAST_AI(aqsentinelAI, nearby[bli]->AI())->gatherOthersWhenAggro = false;
|
||||
CAST_AI(aqsentinelAI, nearby[bli]->AI())->selectAbility(pickAbilityRandom(chosenAbilities));
|
||||
}
|
||||
/*if (bli < 3)
|
||||
DoYell("I dont have enough buddies.", LANG_NEUTRAL, 0);*/
|
||||
@@ -273,7 +273,7 @@ struct TRINITY_DLL_DECL aqsentinelAI : public ScriptedAI
|
||||
DoZoneInCombat();
|
||||
}
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
for (int ni=0; ni<3; ni++)
|
||||
{
|
||||
@@ -286,7 +286,7 @@ struct TRINITY_DLL_DECL aqsentinelAI : public ScriptedAI
|
||||
if (h > sent->GetMaxHealth())
|
||||
h = sent->GetMaxHealth();
|
||||
sent->SetHealth(h);
|
||||
((aqsentinelAI*)sent->AI())->GainSentinelAbility(ability);
|
||||
CAST_AI(aqsentinelAI, sent->AI())->GainSentinelAbility(ability);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -357,13 +357,13 @@ struct TRINITY_DLL_DECL mob_annhylde_the_callerAI : public ScriptedAI
|
||||
Resurect_Phase = 2;
|
||||
}else if (Resurect_Phase == 2)
|
||||
{
|
||||
Unit* ingvar = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_INGVAR));
|
||||
Creature* ingvar = Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_INGVAR));
|
||||
if(ingvar)
|
||||
{
|
||||
ingvar->RemoveAurasDueToSpell(SPELL_SCOURG_RESURRECTION_DUMMY);
|
||||
//ingvar->CastSpell(ingvar,SPELL_INGVAR_TRANSFORM,false);
|
||||
ingvar->SetUInt32Value(UNIT_FIELD_DISPLAYID, MODEL_INGVAR_UNDEAD); // Visual Hack - when he dies he becomes human model -> wrong
|
||||
Creature* c_ingvar = (Creature*)ingvar;
|
||||
Creature* c_ingvar = ingvar;
|
||||
|
||||
CAST_AI(boss_ingvar_the_plundererAI, (c_ingvar->AI()))->StartZombiePhase();
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ struct TRINITY_DLL_DECL boss_akilzonAI : public ScriptedAI
|
||||
{
|
||||
boss_akilzonAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_ELECTRICAL_DAMAGE);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_ELECTRICAL_DAMAGE);
|
||||
if(TempSpell)
|
||||
TempSpell->EffectBasePoints[1] = 49;//disable bugged lightning until fixed in core
|
||||
pInstance = (c->GetInstanceData());
|
||||
@@ -383,7 +383,7 @@ struct TRINITY_DLL_DECL mob_soaring_eagleAI : public ScriptedAI
|
||||
|
||||
void EnterCombat(Unit *who) {DoZoneInCombat();}
|
||||
|
||||
void MoveInLineOfSight(Unit*) {}
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
|
||||
void MovementInform(uint32, uint32)
|
||||
{
|
||||
|
||||
@@ -77,7 +77,7 @@ struct TRINITY_DLL_DECL boss_halazziAI : public ScriptedAI
|
||||
{
|
||||
pInstance = (c->GetInstanceData());
|
||||
// need to find out what controls totem's spell cooldown
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_LIGHTNING);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_LIGHTNING);
|
||||
if(TempSpell && TempSpell->CastingTimeIndex != 5)
|
||||
TempSpell->CastingTimeIndex = 5; // 2000 ms casting time
|
||||
}
|
||||
|
||||
@@ -103,7 +103,7 @@ struct TRINITY_DLL_DECL boss_janalaiAI : public ScriptedAI
|
||||
{
|
||||
pInstance =(c->GetInstanceData());
|
||||
|
||||
SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_HATCH_EGG);
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_HATCH_EGG);
|
||||
if(TempSpell && TempSpell->EffectImplicitTargetA[0] != 1)
|
||||
{
|
||||
TempSpell->EffectImplicitTargetA[0] = 1;
|
||||
@@ -543,8 +543,8 @@ struct TRINITY_DLL_DECL mob_amanishi_hatcherAI : public ScriptedAI
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who) {}
|
||||
void AttackStart(Unit*) {}
|
||||
void MoveInLineOfSight(Unit*) {}
|
||||
void AttackStart(Unit* who) {}
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
void MovementInform(uint32, uint32)
|
||||
{
|
||||
if(waypoint == 5)
|
||||
|
||||
@@ -112,7 +112,7 @@ struct TRINITY_DLL_DECL npc_zulaman_hostageAI : public ScriptedAI
|
||||
uint64 PlayerGUID;
|
||||
void Reset() {}
|
||||
void EnterCombat(Unit *who) {}
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit* who)
|
||||
{
|
||||
Player* player = Unit::GetPlayer(PlayerGUID);
|
||||
if(player) player->SendLoot(m_creature->GetGUID(), LOOT_CORPSE);
|
||||
|
||||
Reference in New Issue
Block a user