* Rename InstanceData to InstanceScript
* Rename *mgr to their new names in scripts project * Mass convert all the scripts (NEEDS THOROUGH TESTING, because it was done automatically) Please, report bugs on issue tracker. --HG-- branch : trunk rename : src/server/game/Instances/InstanceData.cpp => src/server/game/Instances/InstanceScript.cpp rename : src/server/game/Instances/InstanceData.h => src/server/game/Instances/InstanceScript.h
This commit is contained in:
@@ -29,15 +29,18 @@ EndScriptData */
|
||||
#include "zulaman.h"
|
||||
#include "Weather.h"
|
||||
|
||||
#define SPELL_STATIC_DISRUPTION 43622
|
||||
#define SPELL_STATIC_VISUAL 45265
|
||||
#define SPELL_CALL_LIGHTNING 43661 //Missing timer
|
||||
#define SPELL_GUST_OF_WIND 43621
|
||||
#define SPELL_ELECTRICAL_STORM 43648
|
||||
#define SPELL_BERSERK 45078
|
||||
#define SPELL_ELECTRICAL_DAMAGE 43657
|
||||
#define SPELL_ELECTRICAL_OVERLOAD 43658
|
||||
#define SPELL_EAGLE_SWOOP 44732
|
||||
enum Spells
|
||||
{
|
||||
SPELL_STATIC_DISRUPTION = 43622,
|
||||
SPELL_STATIC_VISUAL = 45265,
|
||||
SPELL_CALL_LIGHTNING = 43661, //Missing timer
|
||||
SPELL_GUST_OF_WIND = 43621,
|
||||
SPELL_ELECTRICAL_STORM = 43648,
|
||||
SPELL_BERSERK = 45078,
|
||||
SPELL_ELECTRICAL_DAMAGE = 43657,
|
||||
SPELL_ELECTRICAL_OVERLOAD = 43658,
|
||||
SPELL_EAGLE_SWOOP = 44732
|
||||
};
|
||||
|
||||
//"Your death gonna be quick, strangers. You shoulda never have come to this place..."
|
||||
#define SAY_ONAGGRO "I be da predator! You da prey..."
|
||||
@@ -75,9 +78,9 @@ class boss_akilzon : public CreatureScript
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_ELECTRICAL_DAMAGE);
|
||||
if (TempSpell)
|
||||
TempSpell->EffectBasePoints[1] = 49;//disable bugged lightning until fixed in core
|
||||
pInstance = c->GetInstanceData();
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
|
||||
uint64 BirdGUIDs[8];
|
||||
uint64 TargetGUID;
|
||||
|
||||
@@ -86,14 +86,14 @@ class boss_halazzi : public CreatureScript
|
||||
{
|
||||
boss_halazziAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceData();
|
||||
pInstance = c->GetInstanceScript();
|
||||
// need to find out what controls totem's spell cooldown
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_LIGHTNING);
|
||||
if (TempSpell && TempSpell->CastingTimeIndex != 5)
|
||||
TempSpell->CastingTimeIndex = 5; // 2000 ms casting time
|
||||
}
|
||||
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
|
||||
uint32 FrenzyTimer;
|
||||
uint32 SaberlashTimer;
|
||||
|
||||
@@ -177,11 +177,11 @@ static PlayerAbilityStruct PlayerAbility[][3] =
|
||||
|
||||
struct boss_hexlord_addAI : public ScriptedAI
|
||||
{
|
||||
ScriptedInstance* pInstance;
|
||||
InstanceScript* pInstance;
|
||||
|
||||
boss_hexlord_addAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceData();
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
|
||||
void Reset() {}
|
||||
@@ -213,13 +213,13 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
{
|
||||
boss_hex_lord_malacrassAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceData();
|
||||
pInstance = c->GetInstanceScript();
|
||||
SelectAddEntry();
|
||||
for (uint8 i = 0; i < 4; ++i)
|
||||
AddGUID[i] = 0;
|
||||
}
|
||||
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
|
||||
uint64 AddGUID[4];
|
||||
uint32 AddEntry[4];
|
||||
@@ -469,7 +469,7 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return new boss_hexlord_malacrassAI(creature);
|
||||
return new boss_hex_lord_malacrassAI(creature);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -937,7 +937,7 @@ void AddSC_boss_hex_lord_malacrass()
|
||||
{
|
||||
new boss_hexlord_malacrass();
|
||||
new boss_thurg();
|
||||
new boss_gazakroth();
|
||||
// new boss_gazakroth();
|
||||
new boss_lord_raadan();
|
||||
new boss_darkheart();
|
||||
new boss_slither();
|
||||
|
||||
@@ -114,7 +114,7 @@ class boss_janalai : public CreatureScript
|
||||
{
|
||||
boss_janalaiAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance =c->GetInstanceData();
|
||||
pInstance =c->GetInstanceScript();
|
||||
|
||||
SpellEntry *TempSpell = GET_SPELL(SPELL_HATCH_EGG);
|
||||
if (TempSpell && TempSpell->EffectImplicitTargetA[0] != 1)
|
||||
@@ -124,7 +124,7 @@ class boss_janalai : public CreatureScript
|
||||
}
|
||||
}
|
||||
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
|
||||
uint32 FireBreathTimer;
|
||||
uint32 BombTimer;
|
||||
@@ -493,12 +493,12 @@ class mob_janalai_hatcher : public CreatureScript
|
||||
|
||||
struct mob_janalai_hatcherAI : public ScriptedAI
|
||||
{
|
||||
mob_amanishi_hatcherAI(Creature *c) : ScriptedAI(c)
|
||||
mob_janalai_hatcherAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance =c->GetInstanceData();
|
||||
pInstance =c->GetInstanceScript();
|
||||
}
|
||||
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
|
||||
uint32 waypoint;
|
||||
uint32 HatchNum;
|
||||
@@ -628,10 +628,10 @@ class mob_janalai_hatchling : public CreatureScript
|
||||
{
|
||||
mob_janalai_hatchlingAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance =c->GetInstanceData();
|
||||
pInstance =c->GetInstanceScript();
|
||||
}
|
||||
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
uint32 BuffetTimer;
|
||||
|
||||
void Reset()
|
||||
@@ -676,38 +676,37 @@ class mob_janalai_hatchling : public CreatureScript
|
||||
|
||||
class mob_janalai_egg : public CreatureScript
|
||||
{
|
||||
public:
|
||||
public:
|
||||
|
||||
mob_janalai_egg()
|
||||
: CreatureScript("mob_janalai_egg")
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return new mob_janalai_eggAI(creature);
|
||||
}
|
||||
};
|
||||
|
||||
struct mob_eggAI : public ScriptedAI
|
||||
{
|
||||
mob_eggAI(Creature *c) : ScriptedAI(c){}
|
||||
void Reset() {}
|
||||
void EnterCombat(Unit* /*who*/) {}
|
||||
void AttackStart(Unit* /*who*/) {}
|
||||
void MoveInLineOfSight(Unit* /*who*/) {}
|
||||
void UpdateAI(const uint32 /*diff*/) {}
|
||||
|
||||
void SpellHit(Unit * /*caster*/, const SpellEntry *spell)
|
||||
mob_janalai_egg()
|
||||
: CreatureScript("mob_janalai_egg")
|
||||
{
|
||||
if (spell->Id == SPELL_HATCH_EGG)
|
||||
{
|
||||
DoSpawnCreature(MOB_HATCHLING, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 60000);
|
||||
me->SetDisplayId(11686);
|
||||
}
|
||||
}
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return new mob_janalai_eggAI(creature);
|
||||
}
|
||||
|
||||
struct mob_janalai_eggAI : public ScriptedAI
|
||||
{
|
||||
mob_janalai_eggAI(Creature *c) : ScriptedAI(c){}
|
||||
void Reset() {}
|
||||
void EnterCombat(Unit* /*who*/) {}
|
||||
void AttackStart(Unit* /*who*/) {}
|
||||
void MoveInLineOfSight(Unit* /*who*/) {}
|
||||
void UpdateAI(const uint32 /*diff*/) {}
|
||||
|
||||
void SpellHit(Unit * /*caster*/, const SpellEntry *spell)
|
||||
{
|
||||
if (spell->Id == SPELL_HATCH_EGG)
|
||||
{
|
||||
DoSpawnCreature(MOB_HATCHLING, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 60000);
|
||||
me->SetDisplayId(11686);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
void AddSC_boss_janalai()
|
||||
|
||||
@@ -105,10 +105,10 @@ class boss_nalorakk : public CreatureScript
|
||||
{
|
||||
MoveEvent = true;
|
||||
MovePhase = 0;
|
||||
pInstance = c->GetInstanceData();
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
|
||||
uint32 BrutalSwipe_Timer;
|
||||
uint32 Mangle_Timer;
|
||||
|
||||
@@ -153,9 +153,9 @@ class boss_zuljin : public CreatureScript
|
||||
{
|
||||
boss_zuljinAI(Creature *c) : ScriptedAI(c), Summons(me)
|
||||
{
|
||||
pInstance = c->GetInstanceData();
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
|
||||
uint64 SpiritGUID[4];
|
||||
uint64 ClawTargetGUID;
|
||||
|
||||
@@ -59,9 +59,9 @@ class instance_zulaman : public InstanceMapScript
|
||||
{
|
||||
}
|
||||
|
||||
struct instance_zulaman_InstanceMapScript : public ScriptedInstance
|
||||
struct instance_zulaman_InstanceMapScript : public InstanceScript
|
||||
{
|
||||
instance_zulaman_InstanceMapScript(Map* pMap) : ScriptedInstance(pMap) {Initialize();};
|
||||
instance_zulaman_InstanceMapScript(Map* pMap) : InstanceScript(pMap) {Initialize();};
|
||||
|
||||
uint64 HarkorsSatchelGUID;
|
||||
uint64 TanzarsTrunkGUID;
|
||||
@@ -314,7 +314,7 @@ class instance_zulaman : public InstanceMapScript
|
||||
}
|
||||
};
|
||||
|
||||
InstanceData* GetInstanceData(InstanceMap* pMap) const
|
||||
InstanceScript* GetInstanceScript(InstanceMap* pMap) const
|
||||
{
|
||||
return new instance_zulaman_InstanceMapScript(pMap);
|
||||
}
|
||||
|
||||
@@ -51,10 +51,10 @@ class npc_forest_frog : public CreatureScript
|
||||
{
|
||||
npc_forest_frogAI(Creature* c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceData();
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
|
||||
ScriptedInstance *pInstance;
|
||||
InstanceScript *pInstance;
|
||||
|
||||
void Reset() {}
|
||||
|
||||
@@ -166,7 +166,7 @@ class npc_zulaman_hostage : public CreatureScript
|
||||
return true;
|
||||
pCreature->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP);
|
||||
|
||||
ScriptedInstance* pInstance = pCreature->GetInstanceData();
|
||||
InstanceScript* pInstance = pCreature->GetInstanceScript();
|
||||
if (pInstance)
|
||||
{
|
||||
//uint8 progress = pInstance->GetData(DATA_CHESTLOOTED);
|
||||
|
||||
Reference in New Issue
Block a user