mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-17 02:50:29 +00:00
Big re-organization of repository [W.I.P]
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -1,142 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#ifndef DEF_EYE_OF_ETERNITY_H
|
||||
#define DEF_EYE_OF_ETERNITY_H
|
||||
|
||||
enum Objects
|
||||
{
|
||||
GO_NEXUS_PLATFORM = 193070,
|
||||
GO_IRIS_N = 193958,
|
||||
GO_IRIS_H = 193960,
|
||||
GO_EXIT_PORTAL = 193908,
|
||||
};
|
||||
#define ALEXSTRASZA_GIFT DUNGEON_MODE(193905, 193967)
|
||||
#define HEART_OF_MAGIC DUNGEON_MODE(194158, 194159)
|
||||
|
||||
enum NPCs
|
||||
{
|
||||
NPC_MALYGOS = 28859,
|
||||
NPC_PORTAL = 30118,
|
||||
NPC_WORLD_TRIGGER_LAOI = 22517,
|
||||
NPC_POWER_SPARK = 30084,
|
||||
NPC_VORTEX = 30090,
|
||||
NPC_NEXUS_LORD = 30245,
|
||||
NPC_SCION_OF_ETERNITY = 30249,
|
||||
NPC_HOVER_DISK = 30248,
|
||||
NPC_ARCANE_OVERLOAD = 30282,
|
||||
NPC_SURGE_OF_POWER = 30334,
|
||||
NPC_WYRMREST_SKYTALON = 30161,
|
||||
NPC_STATIC_FIELD = 30592,
|
||||
NPC_ALEXSTRASZA = 32295,
|
||||
};
|
||||
|
||||
enum Data
|
||||
{
|
||||
DATA_IRIS_ACTIVATED,
|
||||
DATA_ENCOUNTER_STATUS,
|
||||
DATA_SET_IRIS_INACTIVE,
|
||||
DATA_HIDE_IRIS_AND_PORTAL,
|
||||
DATA_MALYGOS_GUID,
|
||||
};
|
||||
|
||||
enum eSpells
|
||||
{
|
||||
SPELL_PORTAL_BEAM = 56046,
|
||||
SPELL_IRIS_ACTIVATED = 61012,
|
||||
SPELL_POWER_SPARK_VISUAL = 55845,
|
||||
SPELL_POWER_SPARK_GROUND_BUFF = 55852,
|
||||
SPELL_POWER_SPARK_MALYGOS_BUFF = 56152,
|
||||
|
||||
SPELL_TELEPORT_VISUAL = 52096,
|
||||
|
||||
SPELL_SCION_ARCANE_BARRAGE = 56397,
|
||||
SPELL_ARCANE_SHOCK_N = 57058,
|
||||
SPELL_ARCANE_SHOCK_H = 60073,
|
||||
SPELL_HASTE = 57060,
|
||||
|
||||
SPELL_ALEXSTRASZA_GIFT = 61028,
|
||||
};
|
||||
|
||||
#define SPELL_ARCANE_SHOCK DUNGEON_MODE(SPELL_ARCANE_SHOCK_N, SPELL_ARCANE_SHOCK_H)
|
||||
|
||||
enum eAchiev
|
||||
{
|
||||
ACHIEV_CRITERIA_DENYIN_THE_SCION_10 = 7573,
|
||||
ACHIEV_CRITERIA_DENYIN_THE_SCION_25 = 7574,
|
||||
ACHIEV_CRITERIA_A_POKE_IN_THE_EYE_10 = 7174,
|
||||
ACHIEV_CRITERIA_A_POKE_IN_THE_EYE_25 = 7175,
|
||||
ACHIEV_YOU_DONT_HAVE_AN_ENTERNITY_EVENT = 20387,
|
||||
};
|
||||
|
||||
/*** POSITIONS/WAYPOINTS BELOW ***/
|
||||
|
||||
#define INTRO_MOVEMENT_INTERVAL 25000
|
||||
|
||||
const Position CenterPos = {754.395f, 1301.27f, 266.10f, 0.0f};
|
||||
|
||||
const Position FourSidesPos[] =
|
||||
{
|
||||
{686.417f, 1235.52f, 288.17f, M_PI/4},
|
||||
{828.182f, 1379.05f, 288.17f, 5*M_PI/4},
|
||||
{681.278f, 1375.796f, 288.17f, 7*M_PI/4},
|
||||
{821.182f, 1235.42f, 288.17f, 3*M_PI/4},
|
||||
};
|
||||
|
||||
const Position Phase2NorthPos = {837.22f, 1301.676f, 296.10f, M_PI};
|
||||
|
||||
/*** TEXTS/SOUNDS BELOW ***/
|
||||
|
||||
enum sounds
|
||||
{
|
||||
SOUND_VORTEX = 14525,
|
||||
SOUND_SPARK_BUFF = 14533,
|
||||
|
||||
SOUND_SLAY_1_1 = 14519,
|
||||
SOUND_SLAY_1_2 = 14520,
|
||||
SOUND_SLAY_1_3 = 14521,
|
||||
SOUND_SLAY_2_1 = 14526,
|
||||
SOUND_SLAY_2_2 = 14527,
|
||||
SOUND_SLAY_2_3 = 14528,
|
||||
SOUND_SLAY_3_1 = 14534,
|
||||
SOUND_SLAY_3_2 = 14535,
|
||||
SOUND_SLAY_3_3 = 14536,
|
||||
|
||||
SOUND_AGGRO_1 = 14517,
|
||||
SOUND_AGGRO_2 = 14523,
|
||||
SOUND_DEEP_BREATH = 14518,
|
||||
SOUND_DEATH = 14540,
|
||||
SOUND_PHASE_1_END = 14522,
|
||||
SOUND_PHASE_2_END = 14529,
|
||||
SOUND_PHASE_3_START = 14530
|
||||
};
|
||||
|
||||
struct Speech
|
||||
{
|
||||
uint32 sound;
|
||||
const char* text;
|
||||
};
|
||||
|
||||
const Speech MalygosIntroTexts[] =
|
||||
{
|
||||
{14512, "Lesser beings, intruding here! A shame that your excess courage does not compensate for your stupidity!"},
|
||||
{14513, "None but the blue dragonflight are welcome here! Perhaps this is the work of Alexstrasza? Well then, she has sent you to your deaths."},
|
||||
{14514, "What could you hope to accomplish, to storm brazenly into my domain? To employ MAGIC? Against ME?"},
|
||||
{14515, "I am without limits here... the rules of your cherished reality do not apply... In this realm, I am in control..."},
|
||||
{14516, "I give you one chance. Pledge fealty to me, and perhaps I won\'t slaughter you for your insolence!"},
|
||||
};
|
||||
|
||||
const uint32 MalygosIntroIntervals[] = {18000, 19000, 21000, 18000, 15000};
|
||||
|
||||
class EoEDrakeEnterVehicleEvent : public BasicEvent
|
||||
{
|
||||
public:
|
||||
EoEDrakeEnterVehicleEvent(Creature& owner, uint64 playerGUID) : _owner(owner), _playerGUID(playerGUID) { }
|
||||
bool Execute(uint64 /*eventTime*/, uint32 /*updateTime*/);
|
||||
private:
|
||||
Creature& _owner;
|
||||
uint64 _playerGUID;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,266 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "eye_of_eternity.h"
|
||||
#include "Vehicle.h"
|
||||
#include "Player.h"
|
||||
|
||||
bool EoEDrakeEnterVehicleEvent::Execute(uint64 /*eventTime*/, uint32 /*updateTime*/)
|
||||
{
|
||||
if (Player* p = ObjectAccessor::GetPlayer(_owner, _playerGUID))
|
||||
if (p->IsInWorld() && !p->IsDuringRemoveFromWorld() && !p->isBeingLoaded() && p->FindMap() == _owner.FindMap())
|
||||
{
|
||||
p->CastCustomSpell(60683, SPELLVALUE_BASE_POINT0, 1, &_owner, true);
|
||||
return true;
|
||||
}
|
||||
_owner.DespawnOrUnsummon(1);
|
||||
return true;
|
||||
}
|
||||
|
||||
class instance_eye_of_eternity : public InstanceMapScript
|
||||
{
|
||||
public:
|
||||
instance_eye_of_eternity() : InstanceMapScript("instance_eye_of_eternity", 616) { }
|
||||
|
||||
InstanceScript* GetInstanceScript(InstanceMap* pMap) const
|
||||
{
|
||||
return new instance_eye_of_eternity_InstanceMapScript(pMap);
|
||||
}
|
||||
|
||||
struct instance_eye_of_eternity_InstanceMapScript : public InstanceScript
|
||||
{
|
||||
instance_eye_of_eternity_InstanceMapScript(Map* pMap) : InstanceScript(pMap) { Initialize(); }
|
||||
|
||||
uint32 EncounterStatus;
|
||||
std::string str_data;
|
||||
|
||||
uint64 NPC_MalygosGUID;
|
||||
uint64 GO_IrisGUID;
|
||||
uint64 GO_ExitPortalGUID;
|
||||
uint64 GO_PlatformGUID;
|
||||
bool bPokeAchiev;
|
||||
|
||||
void Initialize()
|
||||
{
|
||||
EncounterStatus = NOT_STARTED;
|
||||
|
||||
NPC_MalygosGUID = 0;
|
||||
GO_IrisGUID = 0;
|
||||
GO_ExitPortalGUID = 0;
|
||||
GO_PlatformGUID = 0;
|
||||
bPokeAchiev = false;
|
||||
}
|
||||
|
||||
bool IsEncounterInProgress() const
|
||||
{
|
||||
return EncounterStatus == IN_PROGRESS;
|
||||
}
|
||||
|
||||
void OnPlayerEnter(Player* pPlayer)
|
||||
{
|
||||
if (EncounterStatus == DONE)
|
||||
{
|
||||
// destroy platform, hide iris (actually ensure, done at loading, but doesn't always work
|
||||
ProcessEvent(NULL, 20158);
|
||||
if (GameObject* go = instance->GetGameObject(GO_IrisGUID))
|
||||
if (go->GetPhaseMask() != 2)
|
||||
go->SetPhaseMask(2, true);
|
||||
|
||||
// no floor, so put players on drakes
|
||||
if (pPlayer)
|
||||
{
|
||||
if (!pPlayer->IsAlive())
|
||||
return;
|
||||
|
||||
if (Creature* c = pPlayer->SummonCreature(NPC_WYRMREST_SKYTALON, pPlayer->GetPositionX(), pPlayer->GetPositionY(), pPlayer->GetPositionZ()-20.0f, 0.0f, TEMPSUMMON_MANUAL_DESPAWN, 0))
|
||||
{
|
||||
c->SetCanFly(true);
|
||||
c->setFaction(pPlayer->getFaction());
|
||||
//pPlayer->CastCustomSpell(60683, SPELLVALUE_BASE_POINT0, 1, c, true);
|
||||
c->m_Events.AddEvent(new EoEDrakeEnterVehicleEvent(*c, pPlayer->GetGUID()), c->m_Events.CalculateTime(500));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
switch(creature->GetEntry())
|
||||
{
|
||||
case NPC_MALYGOS:
|
||||
NPC_MalygosGUID = creature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* go)
|
||||
{
|
||||
switch(go->GetEntry())
|
||||
{
|
||||
case GO_IRIS_N:
|
||||
case GO_IRIS_H:
|
||||
GO_IrisGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_EXIT_PORTAL:
|
||||
GO_ExitPortalGUID = go->GetGUID();
|
||||
break;
|
||||
case GO_NEXUS_PLATFORM:
|
||||
GO_PlatformGUID = go->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32 data)
|
||||
{
|
||||
switch(type)
|
||||
{
|
||||
case DATA_IRIS_ACTIVATED:
|
||||
if (EncounterStatus == NOT_STARTED)
|
||||
if (Creature* c = instance->GetCreature(NPC_MalygosGUID))
|
||||
if (Player* plr = c->SelectNearestPlayer(250.0f))
|
||||
c->AI()->AttackStart(plr);
|
||||
break;
|
||||
case DATA_ENCOUNTER_STATUS:
|
||||
EncounterStatus = data;
|
||||
switch(data)
|
||||
{
|
||||
case NOT_STARTED:
|
||||
bPokeAchiev = false;
|
||||
if (GameObject* go = instance->GetGameObject(GO_IrisGUID))
|
||||
{
|
||||
go->SetPhaseMask(1, true);
|
||||
HandleGameObject(GO_IrisGUID, false, go);
|
||||
}
|
||||
if (GameObject* go = instance->GetGameObject(GO_ExitPortalGUID))
|
||||
go->SetPhaseMask(1, true);
|
||||
if (GameObject* go = instance->GetGameObject(GO_PlatformGUID))
|
||||
{
|
||||
go->SetDestructibleState(GO_DESTRUCTIBLE_REBUILDING, NULL, true);
|
||||
go->EnableCollision(true);
|
||||
}
|
||||
break;
|
||||
case IN_PROGRESS:
|
||||
bPokeAchiev = (instance->GetPlayersCountExceptGMs() < (instance->GetSpawnMode() == 0 ? (uint32)9 : (uint32)21));
|
||||
break;
|
||||
case DONE:
|
||||
bPokeAchiev = false;
|
||||
if (GameObject* go = instance->GetGameObject(GO_ExitPortalGUID))
|
||||
go->SetPhaseMask(1, true);
|
||||
if (Creature* c = instance->GetCreature(NPC_MalygosGUID))
|
||||
if (Creature* alexstrasza = c->SummonCreature(NPC_ALEXSTRASZA, 798.0f, 1268.0f, 299.0f, 2.45f ,TEMPSUMMON_TIMED_DESPAWN, 604800000))
|
||||
break;
|
||||
}
|
||||
if (data == DONE)
|
||||
SaveToDB();
|
||||
break;
|
||||
case DATA_SET_IRIS_INACTIVE:
|
||||
if (GameObject* go = instance->GetGameObject(GO_IrisGUID))
|
||||
{
|
||||
HandleGameObject(GO_IrisGUID, true, go);
|
||||
if (Creature* c = go->SummonCreature(NPC_WORLD_TRIGGER_LAOI, *go, TEMPSUMMON_TIMED_DESPAWN, 10000))
|
||||
c->CastSpell(c, SPELL_IRIS_ACTIVATED, true);
|
||||
}
|
||||
break;
|
||||
case DATA_HIDE_IRIS_AND_PORTAL:
|
||||
if (GameObject* go = instance->GetGameObject(GO_IrisGUID))
|
||||
go->SetPhaseMask(2, true);
|
||||
if (GameObject* go = instance->GetGameObject(GO_ExitPortalGUID))
|
||||
go->SetPhaseMask(2, true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
uint64 GetData64(uint32 type) const
|
||||
{
|
||||
switch(type)
|
||||
{
|
||||
case DATA_MALYGOS_GUID: return NPC_MalygosGUID;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void ProcessEvent(WorldObject* /*unit*/, uint32 eventId)
|
||||
{
|
||||
switch(eventId)
|
||||
{
|
||||
case 20158:
|
||||
if (GameObject* go = instance->GetGameObject(GO_PlatformGUID))
|
||||
if (Creature* c = instance->GetCreature(NPC_MalygosGUID))
|
||||
{
|
||||
go->ModifyHealth(-1000000, c);
|
||||
go->EnableCollision(false);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
std::string GetSaveData()
|
||||
{
|
||||
OUT_SAVE_INST_DATA;
|
||||
std::ostringstream saveStream;
|
||||
saveStream << "E E " << EncounterStatus;
|
||||
str_data = saveStream.str();
|
||||
OUT_SAVE_INST_DATA_COMPLETE;
|
||||
return str_data;
|
||||
}
|
||||
|
||||
void Load(const char* in)
|
||||
{
|
||||
if( !in )
|
||||
{
|
||||
OUT_LOAD_INST_DATA_FAIL;
|
||||
return;
|
||||
}
|
||||
|
||||
OUT_LOAD_INST_DATA(in);
|
||||
|
||||
char dataHead1, dataHead2;
|
||||
uint32 data0;
|
||||
std::istringstream loadStream(in);
|
||||
loadStream >> dataHead1 >> dataHead2 >> data0;
|
||||
|
||||
if( dataHead1 == 'E' && dataHead2 == 'E' )
|
||||
{
|
||||
EncounterStatus = data0;
|
||||
switch(EncounterStatus)
|
||||
{
|
||||
case IN_PROGRESS:
|
||||
EncounterStatus = NOT_STARTED;
|
||||
break;
|
||||
case DONE:
|
||||
// destroy platform, hide iris
|
||||
ProcessEvent(NULL, 20158);
|
||||
if (GameObject* go = instance->GetGameObject(GO_IrisGUID))
|
||||
go->SetPhaseMask(2, true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
else
|
||||
OUT_LOAD_INST_DATA_FAIL;
|
||||
|
||||
OUT_LOAD_INST_DATA_COMPLETE;
|
||||
}
|
||||
|
||||
bool CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* source, Unit const* target = NULL, uint32 miscvalue1 = 0)
|
||||
{
|
||||
switch(criteria_id)
|
||||
{
|
||||
case ACHIEV_CRITERIA_A_POKE_IN_THE_EYE_10:
|
||||
case ACHIEV_CRITERIA_A_POKE_IN_THE_EYE_25:
|
||||
return bPokeAchiev;
|
||||
case ACHIEV_CRITERIA_DENYIN_THE_SCION_10:
|
||||
case ACHIEV_CRITERIA_DENYIN_THE_SCION_25:
|
||||
return (source && source->GetVehicle() && source->GetVehicle()->GetVehicleInfo()->m_ID == 224);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_instance_eye_of_eternity()
|
||||
{
|
||||
new instance_eye_of_eternity();
|
||||
}
|
||||
@@ -1,188 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY XINEF, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "nexus.h"
|
||||
#include "Player.h"
|
||||
#include "SpellInfo.h"
|
||||
|
||||
enum Spells
|
||||
{
|
||||
SPELL_SPARK = 47751,
|
||||
SPELL_RIFT_SHIELD = 47748,
|
||||
SPELL_CHARGE_RIFTS = 47747,
|
||||
SPELL_CREATE_RIFT = 47743,
|
||||
SPELL_ARCANE_ATTRACTION = 57063,
|
||||
SPELL_CLOSE_RIFTS = 47745
|
||||
};
|
||||
|
||||
enum Yells
|
||||
{
|
||||
SAY_AGGRO = 0,
|
||||
SAY_DEATH = 1,
|
||||
SAY_RIFT = 2,
|
||||
EMOTE_RIFT = 3,
|
||||
EMOTE_SHIELD = 4
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_ANOMALUS_SPARK = 1,
|
||||
EVENT_ANOMALUS_HEALTH = 2,
|
||||
EVENT_ANOMALUS_ARCANE_ATTRACTION = 3
|
||||
};
|
||||
|
||||
class ChargeRifts : public BasicEvent
|
||||
{
|
||||
public:
|
||||
ChargeRifts(Creature* caster) : _caster(caster)
|
||||
{
|
||||
}
|
||||
|
||||
bool Execute(uint64 /*execTime*/, uint32 /*diff*/)
|
||||
{
|
||||
_caster->AI()->Talk(EMOTE_SHIELD);
|
||||
_caster->CastSpell(_caster, SPELL_CHARGE_RIFTS, true);
|
||||
return true;
|
||||
}
|
||||
|
||||
private:
|
||||
Creature* _caster;
|
||||
};
|
||||
|
||||
class boss_anomalus : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_anomalus() : CreatureScript("boss_anomalus") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return new boss_anomalusAI (creature);
|
||||
}
|
||||
|
||||
struct boss_anomalusAI : public BossAI
|
||||
{
|
||||
boss_anomalusAI(Creature* creature) : BossAI(creature, DATA_ANOMALUS_EVENT)
|
||||
{
|
||||
}
|
||||
|
||||
bool achievement;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
BossAI::Reset();
|
||||
achievement = true;
|
||||
me->CastSpell(me, SPELL_CLOSE_RIFTS, true);
|
||||
}
|
||||
|
||||
uint32 GetData(uint32 data) const
|
||||
{
|
||||
if (data == me->GetEntry())
|
||||
return achievement;
|
||||
return 0;
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32)
|
||||
{
|
||||
if (type == me->GetEntry())
|
||||
{
|
||||
me->RemoveAura(SPELL_RIFT_SHIELD);
|
||||
me->InterruptNonMeleeSpells(false);
|
||||
achievement = false;
|
||||
}
|
||||
}
|
||||
|
||||
void JustSummoned(Creature* summon)
|
||||
{
|
||||
summons.Summon(summon);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
{
|
||||
Talk(SAY_AGGRO);
|
||||
BossAI::EnterCombat(who);
|
||||
|
||||
events.SetTimer(45000);
|
||||
events.ScheduleEvent(EVENT_ANOMALUS_SPARK, 5000);
|
||||
events.ScheduleEvent(EVENT_ANOMALUS_HEALTH, 1000);
|
||||
if (IsHeroic())
|
||||
events.ScheduleEvent(EVENT_ANOMALUS_ARCANE_ATTRACTION, 8000);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
Talk(SAY_DEATH);
|
||||
BossAI::JustDied(killer);
|
||||
me->CastSpell(me, SPELL_CLOSE_RIFTS, true);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
if (me->HasUnitState(UNIT_STATE_CASTING))
|
||||
return;
|
||||
|
||||
switch (events.ExecuteEvent())
|
||||
{
|
||||
case EVENT_ANOMALUS_HEALTH:
|
||||
if (me->HealthBelowPct(51))
|
||||
{
|
||||
Talk(SAY_RIFT);
|
||||
Talk(EMOTE_RIFT);
|
||||
|
||||
me->CastSpell(me, SPELL_CREATE_RIFT, false);
|
||||
me->CastSpell(me, SPELL_RIFT_SHIELD, true);
|
||||
me->m_Events.AddEvent(new ChargeRifts(me), me->m_Events.CalculateTime(1000));
|
||||
events.DelayEvents(46000);
|
||||
break;
|
||||
}
|
||||
events.ScheduleEvent(EVENT_ANOMALUS_HEALTH, 1000);
|
||||
break;
|
||||
case EVENT_ANOMALUS_SPARK:
|
||||
me->CastSpell(me->GetVictim(), SPELL_SPARK, false);
|
||||
events.ScheduleEvent(EVENT_ANOMALUS_SPARK, 5000);
|
||||
break;
|
||||
case EVENT_ANOMALUS_ARCANE_ATTRACTION:
|
||||
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 50.0f, true))
|
||||
me->CastSpell(target, SPELL_ARCANE_ATTRACTION, false);
|
||||
events.ScheduleEvent(EVENT_ANOMALUS_ARCANE_ATTRACTION, 15000);
|
||||
break;
|
||||
}
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
EnterEvadeIfOutOfCombatArea();
|
||||
}
|
||||
|
||||
bool CheckEvadeIfOutOfCombatArea() const
|
||||
{
|
||||
return me->GetHomePosition().GetExactDist2d(me) > 60.0f;
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
class achievement_chaos_theory : public AchievementCriteriaScript
|
||||
{
|
||||
public:
|
||||
achievement_chaos_theory() : AchievementCriteriaScript("achievement_chaos_theory")
|
||||
{
|
||||
}
|
||||
|
||||
bool OnCheck(Player* /*player*/, Unit* target)
|
||||
{
|
||||
if (!target)
|
||||
return false;
|
||||
|
||||
return target->GetAI()->GetData(target->GetEntry());
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_boss_anomalus()
|
||||
{
|
||||
new boss_anomalus();
|
||||
new achievement_chaos_theory();
|
||||
}
|
||||
@@ -1,119 +0,0 @@
|
||||
/*
|
||||
REWRITTEN BY XINEF
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "nexus.h"
|
||||
|
||||
enum Spells
|
||||
{
|
||||
SPELL_BATTLE_SHOUT = 31403,
|
||||
SPELL_CHARGE = 60067,
|
||||
SPELL_FRIGHTENING_SHOUT = 19134,
|
||||
SPELL_WHIRLWIND = 38618
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_BATTLE_SHOUT = 1,
|
||||
EVENT_FRIGHTENING_SHOUT = 2,
|
||||
EVENT_WHIRLWIND = 3,
|
||||
EVENT_COMMANDER_CHARGE = 4,
|
||||
EVENT_KILL_TALK = 5
|
||||
};
|
||||
|
||||
enum Says
|
||||
{
|
||||
SAY_AGGRO = 0,
|
||||
SAY_DEATH = 1,
|
||||
SAY_KILL = 2
|
||||
};
|
||||
|
||||
class boss_commander_stoutbeard : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_commander_stoutbeard() : CreatureScript("boss_commander_stoutbeard") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return GetInstanceAI<boss_commander_stoutbeardAI>(creature);
|
||||
}
|
||||
|
||||
struct boss_commander_stoutbeardAI : public BossAI
|
||||
{
|
||||
boss_commander_stoutbeardAI(Creature* creature) : BossAI(creature, DATA_COMMANDER_EVENT)
|
||||
{
|
||||
}
|
||||
|
||||
void Reset()
|
||||
{
|
||||
BossAI::Reset();
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
{
|
||||
BossAI::EnterCombat(who);
|
||||
Talk(SAY_AGGRO);
|
||||
|
||||
events.ScheduleEvent(EVENT_BATTLE_SHOUT, 0);
|
||||
events.ScheduleEvent(EVENT_FRIGHTENING_SHOUT, 10000);
|
||||
events.ScheduleEvent(EVENT_WHIRLWIND, 15000);
|
||||
events.ScheduleEvent(EVENT_COMMANDER_CHARGE, 1000);
|
||||
me->RemoveAllAuras();
|
||||
}
|
||||
|
||||
void KilledUnit(Unit*)
|
||||
{
|
||||
if (events.GetNextEventTime(EVENT_KILL_TALK) == 0)
|
||||
{
|
||||
Talk(SAY_KILL);
|
||||
events.ScheduleEvent(EVENT_KILL_TALK, 6000);
|
||||
}
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
BossAI::JustDied(killer);
|
||||
Talk(SAY_DEATH);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
if (me->HasUnitState(UNIT_STATE_CASTING))
|
||||
return;
|
||||
|
||||
switch (events.ExecuteEvent())
|
||||
{
|
||||
case EVENT_BATTLE_SHOUT:
|
||||
me->CastSpell(me, SPELL_BATTLE_SHOUT, true);
|
||||
events.ScheduleEvent(EVENT_BATTLE_SHOUT, 120000);
|
||||
break;
|
||||
case EVENT_FRIGHTENING_SHOUT:
|
||||
me->CastSpell(me->GetVictim(), SPELL_FRIGHTENING_SHOUT, false);
|
||||
events.ScheduleEvent(EVENT_FRIGHTENING_SHOUT, urand(15000, 20000));
|
||||
break;
|
||||
case EVENT_WHIRLWIND:
|
||||
me->CastSpell(me, SPELL_WHIRLWIND, false);
|
||||
events.ScheduleEvent(EVENT_WHIRLWIND, 16000);
|
||||
break;
|
||||
case EVENT_COMMANDER_CHARGE:
|
||||
if (Unit* target = SelectTarget(SELECT_TARGET_FARTHEST, 0, 25.0f))
|
||||
me->CastSpell(target, SPELL_CHARGE, false);
|
||||
events.ScheduleEvent(EVENT_COMMANDER_CHARGE, 20000);
|
||||
break;
|
||||
}
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_boss_commander_stoutbeard()
|
||||
{
|
||||
new boss_commander_stoutbeard();
|
||||
}
|
||||
@@ -1,202 +0,0 @@
|
||||
|
||||
/*
|
||||
REWRITTEN BY XINEF
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "nexus.h"
|
||||
|
||||
enum eEnums
|
||||
{
|
||||
SPELL_FROZEN_PRISON = 47854,
|
||||
SPELL_TAIL_SWEEP = 50155,
|
||||
SPELL_CRYSTAL_CHAINS = 50997,
|
||||
SPELL_ENRAGE = 8599,
|
||||
SPELL_CRYSTALFIRE_BREATH = 48096,
|
||||
SPELL_CRYSTALIZE = 48179,
|
||||
SPELL_INTENSE_COLD = 48094,
|
||||
SPELL_INTENSE_COLD_TRIGGER = 48095,
|
||||
};
|
||||
|
||||
enum Yells
|
||||
{
|
||||
SAY_AGGRO = 0,
|
||||
SAY_SLAY = 1,
|
||||
SAY_ENRAGE = 2,
|
||||
SAY_DEATH = 3,
|
||||
SAY_CRYSTAL_NOVA = 4,
|
||||
EMOTE_FRENZY = 5
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_CRYSTALFIRE_BREATH = 1,
|
||||
EVENT_CRYSTAL_CHAINS = 2,
|
||||
EVENT_TAIL_SWEEP = 3,
|
||||
EVENT_HEALTH_CHECK = 4,
|
||||
EVENT_ACHIEVEMENT_CHECK = 5,
|
||||
EVENT_KILL_TALK = 6
|
||||
};
|
||||
|
||||
class boss_keristrasza : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_keristrasza() : CreatureScript("boss_keristrasza") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return GetInstanceAI<boss_keristraszaAI>(creature);
|
||||
}
|
||||
|
||||
struct boss_keristraszaAI : public BossAI
|
||||
{
|
||||
boss_keristraszaAI(Creature* creature) : BossAI(creature, DATA_KERISTRASZA_EVENT)
|
||||
{
|
||||
}
|
||||
|
||||
std::set<uint32> aGuids;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
BossAI::Reset();
|
||||
RemovePrison(CanRemovePrison());
|
||||
aGuids.clear();
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
{
|
||||
Talk(SAY_AGGRO);
|
||||
BossAI::EnterCombat(who);
|
||||
|
||||
me->CastSpell(me, SPELL_INTENSE_COLD, true);
|
||||
events.ScheduleEvent(EVENT_CRYSTALFIRE_BREATH, 14000);
|
||||
events.ScheduleEvent(EVENT_CRYSTAL_CHAINS, DUNGEON_MODE(20000,11000));
|
||||
events.ScheduleEvent(EVENT_TAIL_SWEEP, 5000);
|
||||
events.ScheduleEvent(EVENT_HEALTH_CHECK, 1000);
|
||||
events.ScheduleEvent(EVENT_ACHIEVEMENT_CHECK, 1000);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
Talk(SAY_DEATH);
|
||||
BossAI::JustDied(killer);
|
||||
}
|
||||
|
||||
void KilledUnit(Unit*)
|
||||
{
|
||||
if (events.GetNextEventTime(EVENT_KILL_TALK) == 0)
|
||||
{
|
||||
Talk(SAY_SLAY);
|
||||
events.ScheduleEvent(EVENT_KILL_TALK, 6000);
|
||||
}
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32)
|
||||
{
|
||||
if (type == me->GetEntry() && CanRemovePrison())
|
||||
RemovePrison(true);
|
||||
}
|
||||
|
||||
bool CanRemovePrison()
|
||||
{
|
||||
for (uint8 i = DATA_TELESTRA_ORB; i <= DATA_ORMOROK_ORB; ++i)
|
||||
if (instance->GetBossState(i) != DONE)
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void RemovePrison(bool remove)
|
||||
{
|
||||
if (remove)
|
||||
{
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->RemoveAurasDueToSpell(SPELL_FROZEN_PRISON);
|
||||
}
|
||||
else
|
||||
{
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->CastSpell(me, SPELL_FROZEN_PRISON, true);
|
||||
}
|
||||
}
|
||||
|
||||
uint32 GetData(uint32 guid) const
|
||||
{
|
||||
return aGuids.find(guid) == aGuids.end();
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
if (me->HasUnitState(UNIT_STATE_CASTING))
|
||||
return;
|
||||
|
||||
switch (events.ExecuteEvent())
|
||||
{
|
||||
case EVENT_HEALTH_CHECK:
|
||||
if (me->HealthBelowPct(26))
|
||||
{
|
||||
Talk(SAY_ENRAGE);
|
||||
Talk(EMOTE_FRENZY);
|
||||
me->CastSpell(me, SPELL_ENRAGE, true);
|
||||
break;
|
||||
}
|
||||
events.ScheduleEvent(EVENT_HEALTH_CHECK, 1000);
|
||||
break;
|
||||
case EVENT_ACHIEVEMENT_CHECK:
|
||||
{
|
||||
Map::PlayerList const& pList = me->GetMap()->GetPlayers();
|
||||
for(Map::PlayerList::const_iterator itr = pList.begin(); itr != pList.end(); ++itr)
|
||||
if (Aura *aur = itr->GetSource()->GetAura(SPELL_INTENSE_COLD_TRIGGER))
|
||||
if (aur->GetStackAmount() > 2)
|
||||
aGuids.insert(itr->GetSource()->GetGUIDLow());
|
||||
events.ScheduleEvent(EVENT_ACHIEVEMENT_CHECK, 500);
|
||||
break;
|
||||
}
|
||||
case EVENT_CRYSTALFIRE_BREATH:
|
||||
me->CastSpell(me->GetVictim(), SPELL_CRYSTALFIRE_BREATH, false);
|
||||
events.ScheduleEvent(EVENT_CRYSTALFIRE_BREATH, 14000);
|
||||
break;
|
||||
case EVENT_TAIL_SWEEP:
|
||||
me->CastSpell(me, SPELL_TAIL_SWEEP, false);
|
||||
events.ScheduleEvent(EVENT_TAIL_SWEEP, 5000);
|
||||
break;
|
||||
case EVENT_CRYSTAL_CHAINS:
|
||||
Talk(SAY_CRYSTAL_NOVA);
|
||||
if (IsHeroic())
|
||||
me->CastSpell(me, SPELL_CRYSTALIZE, false);
|
||||
else if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 40.0f, true))
|
||||
me->CastSpell(target, SPELL_CRYSTAL_CHAINS, false);
|
||||
events.ScheduleEvent(EVENT_CRYSTAL_CHAINS, DUNGEON_MODE(20000, 11000));
|
||||
break;
|
||||
}
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
class achievement_intense_cold : public AchievementCriteriaScript
|
||||
{
|
||||
public:
|
||||
achievement_intense_cold() : AchievementCriteriaScript("achievement_intense_cold")
|
||||
{
|
||||
}
|
||||
|
||||
bool OnCheck(Player* player, Unit* target)
|
||||
{
|
||||
if (!target)
|
||||
return false;
|
||||
|
||||
return target->GetAI()->GetData(player->GetGUIDLow());
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_boss_keristrasza()
|
||||
{
|
||||
new boss_keristrasza();
|
||||
new achievement_intense_cold();
|
||||
}
|
||||
@@ -1,336 +0,0 @@
|
||||
/*
|
||||
REWRITTEN BY XINEF
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "nexus.h"
|
||||
|
||||
enum Spells
|
||||
{
|
||||
// Main
|
||||
SPELL_ICE_NOVA = 47772,
|
||||
SPELL_FIREBOMB = 47773,
|
||||
|
||||
SPELL_GRAVITY_WELL = 47756,
|
||||
SPELL_TELESTRA_BACK = 47714,
|
||||
SPELL_BURNING_WINDS = 46308,
|
||||
SPELL_START_SUMMON_CLONES = 47710,
|
||||
|
||||
SPELL_FIRE_MAGUS_SUMMON = 47707,
|
||||
SPELL_FROST_MAGUS_SUMMON = 47709,
|
||||
SPELL_ARCANE_MAGUS_SUMMON = 47708,
|
||||
|
||||
SPELL_FIRE_MAGUS_DEATH = 47711,
|
||||
SPELL_ARCANE_MAGUS_DEATH = 47713,
|
||||
|
||||
SPELL_WEAR_CHRISTMAS_HAT = 61400
|
||||
};
|
||||
|
||||
enum Yells
|
||||
{
|
||||
SAY_AGGRO = 0,
|
||||
SAY_KILL = 1,
|
||||
SAY_DEATH = 2,
|
||||
SAY_MERGE = 3,
|
||||
SAY_SPLIT = 4
|
||||
};
|
||||
|
||||
enum Misc
|
||||
{
|
||||
NPC_FIRE_MAGUS = 26928,
|
||||
NPC_FROST_MAGUS = 26930,
|
||||
NPC_ARCANE_MAGUS = 26929,
|
||||
|
||||
ACHIEVEMENT_SPLIT_PERSONALITY = 2150,
|
||||
|
||||
GAME_EVENT_WINTER_VEIL = 2,
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_MAGUS_ICE_NOVA = 1,
|
||||
EVENT_MAGUS_FIREBOMB = 2,
|
||||
EVENT_MAGUS_GRAVITY_WELL = 3,
|
||||
EVENT_MAGUS_HEALTH1 = 4,
|
||||
EVENT_MAGUS_HEALTH2 = 5,
|
||||
EVENT_MAGUS_FAIL_ACHIEVEMENT = 6,
|
||||
EVENT_MAGUS_MERGED = 7,
|
||||
EVENT_MAGUS_RELOCATE = 8,
|
||||
EVENT_KILL_TALK = 9
|
||||
};
|
||||
|
||||
class boss_magus_telestra : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_magus_telestra() : CreatureScript("boss_magus_telestra") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return GetInstanceAI<boss_magus_telestraAI>(creature);
|
||||
}
|
||||
|
||||
struct boss_magus_telestraAI : public BossAI
|
||||
{
|
||||
boss_magus_telestraAI(Creature* creature) : BossAI(creature, DATA_MAGUS_TELESTRA_EVENT)
|
||||
{
|
||||
}
|
||||
|
||||
uint8 copiesDied;
|
||||
bool achievement;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
BossAI::Reset();
|
||||
copiesDied = 0;
|
||||
achievement = true;
|
||||
|
||||
if (IsHeroic() && sGameEventMgr->IsActiveEvent(GAME_EVENT_WINTER_VEIL) && !me->HasAura(SPELL_WEAR_CHRISTMAS_HAT))
|
||||
me->AddAura(SPELL_WEAR_CHRISTMAS_HAT, me);
|
||||
}
|
||||
|
||||
uint32 GetData(uint32 data) const
|
||||
{
|
||||
if (data == me->GetEntry())
|
||||
return achievement;
|
||||
return 0;
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
{
|
||||
BossAI::EnterCombat(who);
|
||||
Talk(SAY_AGGRO);
|
||||
|
||||
events.ScheduleEvent(EVENT_MAGUS_ICE_NOVA, 10000);
|
||||
events.ScheduleEvent(EVENT_MAGUS_FIREBOMB, 0);
|
||||
events.ScheduleEvent(EVENT_MAGUS_GRAVITY_WELL, 20000);
|
||||
events.ScheduleEvent(EVENT_MAGUS_HEALTH1, 1000);
|
||||
if (IsHeroic())
|
||||
events.ScheduleEvent(EVENT_MAGUS_HEALTH2, 1000);
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who)
|
||||
{
|
||||
if (who && me->Attack(who, true))
|
||||
me->GetMotionMaster()->MoveChase(who, 20.0f);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
BossAI::JustDied(killer);
|
||||
Talk(SAY_DEATH);
|
||||
}
|
||||
|
||||
void KilledUnit(Unit*)
|
||||
{
|
||||
if (events.GetNextEventTime(EVENT_KILL_TALK) == 0)
|
||||
{
|
||||
Talk(SAY_KILL);
|
||||
events.ScheduleEvent(EVENT_KILL_TALK, 6000);
|
||||
}
|
||||
}
|
||||
|
||||
void JustSummoned(Creature* summon)
|
||||
{
|
||||
summons.Summon(summon);
|
||||
summon->SetInCombatWithZone();
|
||||
}
|
||||
|
||||
void SpellHit(Unit* caster, const SpellInfo* spellInfo)
|
||||
{
|
||||
if (spellInfo->Id >= SPELL_FIRE_MAGUS_DEATH && spellInfo->Id <= SPELL_ARCANE_MAGUS_DEATH && caster->ToCreature())
|
||||
{
|
||||
events.ScheduleEvent(EVENT_MAGUS_FAIL_ACHIEVEMENT, 5000);
|
||||
caster->ToCreature()->DespawnOrUnsummon(1000);
|
||||
|
||||
if (++copiesDied >= 3)
|
||||
{
|
||||
copiesDied = 0;
|
||||
Talk(SAY_MERGE);
|
||||
events.CancelEvent(EVENT_MAGUS_FAIL_ACHIEVEMENT);
|
||||
events.ScheduleEvent(EVENT_MAGUS_MERGED, 5000);
|
||||
me->CastSpell(me, SPELL_BURNING_WINDS, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
if (me->HasUnitState(UNIT_STATE_CASTING))
|
||||
return;
|
||||
|
||||
switch (events.ExecuteEvent())
|
||||
{
|
||||
case EVENT_MAGUS_HEALTH1:
|
||||
if (me->HealthBelowPct(51))
|
||||
{
|
||||
me->CastSpell(me, SPELL_START_SUMMON_CLONES, false);
|
||||
events.ScheduleEvent(EVENT_MAGUS_RELOCATE, 3500);
|
||||
break;
|
||||
}
|
||||
events.ScheduleEvent(EVENT_MAGUS_HEALTH1, 1000);
|
||||
break;
|
||||
case EVENT_MAGUS_HEALTH2:
|
||||
if (me->HealthBelowPct(11))
|
||||
{
|
||||
me->CastSpell(me, SPELL_START_SUMMON_CLONES, false);
|
||||
events.ScheduleEvent(EVENT_MAGUS_RELOCATE, 3500);
|
||||
break;
|
||||
}
|
||||
events.ScheduleEvent(EVENT_MAGUS_HEALTH2, 1000);
|
||||
break;
|
||||
case EVENT_MAGUS_FIREBOMB:
|
||||
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0))
|
||||
me->CastSpell(target, SPELL_FIREBOMB, false);
|
||||
events.ScheduleEvent(EVENT_MAGUS_FIREBOMB, 3000);
|
||||
break;
|
||||
case EVENT_MAGUS_ICE_NOVA:
|
||||
me->CastSpell(me, SPELL_ICE_NOVA, false);
|
||||
events.ScheduleEvent(EVENT_MAGUS_ICE_NOVA, 15000);
|
||||
break;
|
||||
case EVENT_MAGUS_GRAVITY_WELL:
|
||||
me->CastSpell(me, SPELL_GRAVITY_WELL, false);
|
||||
events.ScheduleEvent(EVENT_MAGUS_GRAVITY_WELL, 15000);
|
||||
break;
|
||||
case EVENT_MAGUS_FAIL_ACHIEVEMENT:
|
||||
achievement = false;
|
||||
break;
|
||||
case EVENT_MAGUS_RELOCATE:
|
||||
me->NearTeleportTo(505.04f, 88.915f, -16.13f, 2.98f);
|
||||
break;
|
||||
case EVENT_MAGUS_MERGED:
|
||||
me->CastSpell(me, SPELL_TELESTRA_BACK, true);
|
||||
me->RemoveAllAuras();
|
||||
break;
|
||||
}
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
class spell_boss_magus_telestra_summon_telestra_clones : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_boss_magus_telestra_summon_telestra_clones() : SpellScriptLoader("spell_boss_magus_telestra_summon_telestra_clones") { }
|
||||
|
||||
class spell_boss_magus_telestra_summon_telestra_clones_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_boss_magus_telestra_summon_telestra_clones_AuraScript);
|
||||
|
||||
bool Load()
|
||||
{
|
||||
return GetUnitOwner()->GetTypeId() == TYPEID_UNIT;
|
||||
}
|
||||
|
||||
void HandleApply(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/)
|
||||
{
|
||||
GetUnitOwner()->ToCreature()->AI()->Talk(SAY_SPLIT);
|
||||
GetUnitOwner()->CastSpell(GetUnitOwner(), SPELL_FIRE_MAGUS_SUMMON, true);
|
||||
GetUnitOwner()->CastSpell(GetUnitOwner(), SPELL_FROST_MAGUS_SUMMON, true);
|
||||
GetUnitOwner()->CastSpell(GetUnitOwner(), SPELL_ARCANE_MAGUS_SUMMON, true);
|
||||
|
||||
GetUnitOwner()->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
|
||||
GetUnitOwner()->SetControlled(true, UNIT_STATE_STUNNED);
|
||||
GetUnitOwner()->ToCreature()->LoadEquipment(0, true);
|
||||
|
||||
}
|
||||
|
||||
void HandleRemove(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/)
|
||||
{
|
||||
GetUnitOwner()->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
|
||||
GetUnitOwner()->SetControlled(false, UNIT_STATE_STUNNED);
|
||||
GetUnitOwner()->ToCreature()->LoadEquipment(1, true);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
AfterEffectApply += AuraEffectApplyFn(spell_boss_magus_telestra_summon_telestra_clones_AuraScript::HandleApply, EFFECT_1, SPELL_AURA_TRANSFORM, AURA_EFFECT_HANDLE_REAL);
|
||||
AfterEffectRemove += AuraEffectRemoveFn(spell_boss_magus_telestra_summon_telestra_clones_AuraScript::HandleRemove, EFFECT_1, SPELL_AURA_TRANSFORM, AURA_EFFECT_HANDLE_REAL);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_boss_magus_telestra_summon_telestra_clones_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
class spell_boss_magus_telestra_gravity_well : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_boss_magus_telestra_gravity_well() : SpellScriptLoader("spell_boss_magus_telestra_gravity_well") { }
|
||||
|
||||
class spell_boss_magus_telestra_gravity_well_SpellScript : public SpellScript
|
||||
{
|
||||
PrepareSpellScript(spell_boss_magus_telestra_gravity_well_SpellScript);
|
||||
|
||||
void SelectTarget(std::list<WorldObject*>& targets)
|
||||
{
|
||||
targets.remove_if(Trinity::RandomCheck(50));
|
||||
}
|
||||
|
||||
void HandlePull(SpellEffIndex effIndex)
|
||||
{
|
||||
PreventHitDefaultEffect(effIndex);
|
||||
Unit* target = GetHitUnit();
|
||||
if (!target)
|
||||
return;
|
||||
|
||||
Position pos;
|
||||
if (target->GetDistance(GetCaster()) < 5.0f)
|
||||
{
|
||||
pos.Relocate(GetCaster()->GetPositionX(), GetCaster()->GetPositionY(), GetCaster()->GetPositionZ()+1.0f);
|
||||
float o = frand(0, 2*M_PI);
|
||||
target->MovePositionToFirstCollision(pos, 20.0f, frand(0, 2*M_PI));
|
||||
pos.m_positionZ += frand(5.0f, 15.0f);
|
||||
}
|
||||
else
|
||||
pos.Relocate(GetCaster()->GetPositionX(), GetCaster()->GetPositionY(), GetCaster()->GetPositionZ()+1.0f);
|
||||
|
||||
float speedXY = float(GetSpellInfo()->Effects[effIndex].MiscValue) * 0.1f;
|
||||
float speedZ = target->GetDistance(pos) / speedXY * 0.5f * Movement::gravity;
|
||||
|
||||
target->GetMotionMaster()->MoveJump(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), speedXY, speedZ);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_boss_magus_telestra_gravity_well_SpellScript::SelectTarget, EFFECT_0, TARGET_UNIT_SRC_AREA_ENEMY);
|
||||
OnEffectHitTarget += SpellEffectFn(spell_boss_magus_telestra_gravity_well_SpellScript::HandlePull, EFFECT_0, SPELL_EFFECT_PULL_TOWARDS_DEST);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
{
|
||||
return new spell_boss_magus_telestra_gravity_well_SpellScript();
|
||||
}
|
||||
};
|
||||
|
||||
class achievement_split_personality : public AchievementCriteriaScript
|
||||
{
|
||||
public:
|
||||
achievement_split_personality() : AchievementCriteriaScript("achievement_split_personality")
|
||||
{
|
||||
}
|
||||
|
||||
bool OnCheck(Player* /*player*/, Unit* target)
|
||||
{
|
||||
if (!target)
|
||||
return false;
|
||||
|
||||
return target->GetAI()->GetData(target->GetEntry());
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_boss_magus_telestra()
|
||||
{
|
||||
new boss_magus_telestra();
|
||||
new spell_boss_magus_telestra_summon_telestra_clones();
|
||||
new spell_boss_magus_telestra_gravity_well();
|
||||
new achievement_split_personality();
|
||||
}
|
||||
@@ -1,216 +0,0 @@
|
||||
/*
|
||||
REWRITTEN BY XINEF
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "nexus.h"
|
||||
#include "Player.h"
|
||||
|
||||
enum eEnums
|
||||
{
|
||||
SPELL_CRYSTAL_SPIKES = 47958,
|
||||
SPELL_CRYSTAL_SPIKE_DAMAGE = 47944,
|
||||
SPELL_CRYSTAL_SPIKE_PREVISUAL = 50442,
|
||||
SPELL_SPELL_REFLECTION = 47981,
|
||||
SPELL_TRAMPLE = 48016,
|
||||
SPELL_FRENZY = 48017,
|
||||
SPELL_SUMMON_CRYSTALLINE_TANGLER = 61564,
|
||||
SPELL_CRYSTAL_CHAINS = 47698,
|
||||
};
|
||||
|
||||
enum Yells
|
||||
{
|
||||
SAY_AGGRO = 1,
|
||||
SAY_DEATH = 2,
|
||||
SAY_REFLECT = 3,
|
||||
SAY_CRYSTAL_SPIKES = 4,
|
||||
SAY_KILL = 5,
|
||||
EMOTE_FRENZY = 6
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_ORMOROK_CRYSTAL_SPIKES = 1,
|
||||
EVENT_ORMOROK_TRAMPLE = 2,
|
||||
EVENT_ORMOROK_SPELL_REFLECTION = 3,
|
||||
EVENT_ORMOROK_SUMMON = 4,
|
||||
EVENT_ORMOROK_HEALTH = 5,
|
||||
EVENT_ORMOROK_SUMMON_SPIKES = 6,
|
||||
EVENT_KILL_TALK = 7
|
||||
};
|
||||
|
||||
enum Misc
|
||||
{
|
||||
NPC_CRYSTAL_SPIKE = 27099,
|
||||
NPC_CRYSTALLINE_TANGLER = 32665,
|
||||
GO_CRYSTAL_SPIKE = 188537
|
||||
};
|
||||
|
||||
class boss_ormorok : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_ormorok() : CreatureScript("boss_ormorok") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return GetInstanceAI<boss_ormorokAI>(creature);
|
||||
}
|
||||
|
||||
struct boss_ormorokAI : public BossAI
|
||||
{
|
||||
boss_ormorokAI(Creature* creature) : BossAI(creature, DATA_ORMOROK_EVENT)
|
||||
{
|
||||
}
|
||||
|
||||
uint8 _spikesCount;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
_spikesCount = 0;
|
||||
BossAI::Reset();
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
{
|
||||
Talk(SAY_AGGRO);
|
||||
BossAI::EnterCombat(who);
|
||||
|
||||
events.ScheduleEvent(EVENT_ORMOROK_CRYSTAL_SPIKES, 12000);
|
||||
events.ScheduleEvent(EVENT_ORMOROK_TRAMPLE, 10000);
|
||||
events.ScheduleEvent(EVENT_ORMOROK_SPELL_REFLECTION, 30000);
|
||||
events.ScheduleEvent(EVENT_ORMOROK_HEALTH, 1000);
|
||||
if (IsHeroic())
|
||||
events.ScheduleEvent(EVENT_ORMOROK_SUMMON, 17000);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
Talk(SAY_DEATH);
|
||||
BossAI::JustDied(killer);
|
||||
}
|
||||
|
||||
void KilledUnit(Unit *victim)
|
||||
{
|
||||
if (events.GetNextEventTime(EVENT_KILL_TALK) == 0)
|
||||
{
|
||||
Talk(SAY_KILL);
|
||||
events.ScheduleEvent(EVENT_KILL_TALK, 6000);
|
||||
}
|
||||
}
|
||||
|
||||
void JustSummoned(Creature* summon)
|
||||
{
|
||||
summons.Summon(summon);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
if (me->HasUnitState(UNIT_STATE_CASTING))
|
||||
return;
|
||||
|
||||
switch (events.ExecuteEvent())
|
||||
{
|
||||
case EVENT_ORMOROK_HEALTH:
|
||||
if (me->HealthBelowPct(26))
|
||||
{
|
||||
me->CastSpell(me, SPELL_FRENZY, true);
|
||||
Talk(EMOTE_FRENZY);
|
||||
break;
|
||||
}
|
||||
events.ScheduleEvent(EVENT_ORMOROK_HEALTH, 1000);
|
||||
break;
|
||||
case EVENT_ORMOROK_TRAMPLE:
|
||||
me->CastSpell(me, SPELL_TRAMPLE, false);
|
||||
events.ScheduleEvent(EVENT_ORMOROK_TRAMPLE, 10000);
|
||||
break;
|
||||
case EVENT_ORMOROK_SPELL_REFLECTION:
|
||||
Talk(SAY_REFLECT);
|
||||
me->CastSpell(me, SPELL_SPELL_REFLECTION, false);
|
||||
events.ScheduleEvent(EVENT_ORMOROK_SPELL_REFLECTION, 30000);
|
||||
break;
|
||||
case EVENT_ORMOROK_SUMMON:
|
||||
if (Unit* target = SelectTarget(SELECT_TARGET_FARTHEST, 0, 50.0f, true))
|
||||
me->CastSpell(target, SPELL_SUMMON_CRYSTALLINE_TANGLER, true);
|
||||
events.ScheduleEvent(EVENT_ORMOROK_SUMMON, 17000);
|
||||
break;
|
||||
case EVENT_ORMOROK_CRYSTAL_SPIKES:
|
||||
Talk(SAY_CRYSTAL_SPIKES);
|
||||
me->CastSpell(me, SPELL_CRYSTAL_SPIKES, false);
|
||||
_spikesCount = 0;
|
||||
events.ScheduleEvent(EVENT_ORMOROK_SUMMON_SPIKES, 300);
|
||||
events.ScheduleEvent(EVENT_ORMOROK_CRYSTAL_SPIKES, 20000);
|
||||
break;
|
||||
case EVENT_ORMOROK_SUMMON_SPIKES:
|
||||
if (++_spikesCount > 9)
|
||||
break;
|
||||
for (uint8 i = 0; i < 4; ++i)
|
||||
{
|
||||
float o = rand_norm()*2.0f*M_PI;
|
||||
float x = me->GetPositionX()+5.0f*_spikesCount*cos(o);
|
||||
float y = me->GetPositionY()+5.0f*_spikesCount*sin(o);
|
||||
me->SummonCreature(NPC_CRYSTAL_SPIKE, x, y, me->GetMap()->GetHeight(x, y, me->GetPositionZ()+5.0f), 0, TEMPSUMMON_TIMED_DESPAWN, 7000);
|
||||
}
|
||||
events.ScheduleEvent(EVENT_ORMOROK_SUMMON_SPIKES, 200);
|
||||
break;
|
||||
}
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
class npc_crystal_spike : public CreatureScript
|
||||
{
|
||||
public:
|
||||
npc_crystal_spike() : CreatureScript("npc_crystal_spike") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* pCreature) const
|
||||
{
|
||||
return GetInstanceAI<npc_crystal_spikeAI>(pCreature);
|
||||
}
|
||||
|
||||
struct npc_crystal_spikeAI : public NullCreatureAI
|
||||
{
|
||||
npc_crystal_spikeAI(Creature *c) : NullCreatureAI(c)
|
||||
{
|
||||
}
|
||||
|
||||
int32 _damageTimer;
|
||||
uint64 _gameObjectGUID;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
if (GameObject* gameobject = me->SummonGameObject(GO_CRYSTAL_SPIKE, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 3500))
|
||||
_gameObjectGUID = gameobject->GetGUID();
|
||||
|
||||
_damageTimer = 1;
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if (_damageTimer)
|
||||
{
|
||||
_damageTimer += diff;
|
||||
if (_damageTimer >= 2000)
|
||||
{
|
||||
if (GameObject* gameobject = ObjectAccessor::GetGameObject(*me, _gameObjectGUID))
|
||||
gameobject->SetGoState(GO_STATE_ACTIVE);
|
||||
|
||||
me->CastSpell(me, SPELL_CRYSTAL_SPIKE_DAMAGE, false);
|
||||
_damageTimer = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_boss_ormorok()
|
||||
{
|
||||
new boss_ormorok();
|
||||
new npc_crystal_spike();
|
||||
}
|
||||
@@ -1,284 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY XINEF, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "nexus.h"
|
||||
|
||||
DoorData const doorData[] =
|
||||
{
|
||||
{ GO_TELESTRA_SPHERE, DATA_TELESTRA_ORB, DOOR_TYPE_PASSAGE, BOUNDARY_NONE },
|
||||
{ GO_ANOMALUS_SPHERE, DATA_ANOMALUS_ORB, DOOR_TYPE_PASSAGE, BOUNDARY_NONE },
|
||||
{ GO_ORMOROK_SPHERE, DATA_ORMOROK_ORB, DOOR_TYPE_PASSAGE, BOUNDARY_NONE },
|
||||
{ 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE }
|
||||
};
|
||||
|
||||
class instance_nexus : public InstanceMapScript
|
||||
{
|
||||
public:
|
||||
instance_nexus() : InstanceMapScript("instance_nexus", 576) { }
|
||||
|
||||
InstanceScript* GetInstanceScript(InstanceMap* map) const
|
||||
{
|
||||
return new instance_nexus_InstanceMapScript(map);
|
||||
}
|
||||
|
||||
struct instance_nexus_InstanceMapScript : public InstanceScript
|
||||
{
|
||||
instance_nexus_InstanceMapScript(Map* map) : InstanceScript(map) {}
|
||||
|
||||
void Initialize()
|
||||
{
|
||||
SetBossNumber(MAX_ENCOUNTERS);
|
||||
LoadDoorData(doorData);
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* creature)
|
||||
{
|
||||
Map::PlayerList const& players = instance->GetPlayers();
|
||||
TeamId TeamIdInInstance = TEAM_NEUTRAL;
|
||||
if (!players.isEmpty())
|
||||
if (Player* pPlayer = players.begin()->GetSource())
|
||||
TeamIdInInstance = pPlayer->GetTeamId();
|
||||
|
||||
switch (creature->GetEntry())
|
||||
{
|
||||
case NPC_ALLIANCE_RANGER:
|
||||
creature->setFaction(16);
|
||||
if (TeamIdInInstance == TEAM_ALLIANCE)
|
||||
creature->UpdateEntry(NPC_HORDE_RANGER);
|
||||
break;
|
||||
case NPC_ALLIANCE_BERSERKER:
|
||||
creature->setFaction(16);
|
||||
if (TeamIdInInstance == TEAM_ALLIANCE)
|
||||
creature->UpdateEntry(NPC_HORDE_BERSERKER);
|
||||
break;
|
||||
case NPC_ALLIANCE_COMMANDER:
|
||||
creature->setFaction(16);
|
||||
if (TeamIdInInstance == TEAM_ALLIANCE)
|
||||
creature->UpdateEntry(NPC_HORDE_COMMANDER);
|
||||
break;
|
||||
case NPC_ALLIANCE_CLERIC:
|
||||
creature->setFaction(16);
|
||||
if (TeamIdInInstance == TEAM_ALLIANCE)
|
||||
creature->UpdateEntry(NPC_HORDE_CLERIC);
|
||||
break;
|
||||
case NPC_COMMANDER_STOUTBEARD:
|
||||
creature->setFaction(16);
|
||||
if (TeamIdInInstance == TEAM_ALLIANCE)
|
||||
creature->UpdateEntry(NPC_COMMANDER_KOLURG);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* gameObject)
|
||||
{
|
||||
switch (gameObject->GetEntry())
|
||||
{
|
||||
case GO_TELESTRA_SPHERE:
|
||||
if (GetBossState(DATA_TELESTRA_ORB) != DONE && GetBossState(DATA_MAGUS_TELESTRA_EVENT) == DONE)
|
||||
gameObject->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE);
|
||||
AddDoor(gameObject, true);
|
||||
break;
|
||||
case GO_ANOMALUS_SPHERE:
|
||||
if (GetBossState(DATA_ANOMALUS_ORB) != DONE && GetBossState(DATA_ANOMALUS_EVENT) == DONE)
|
||||
gameObject->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE);
|
||||
AddDoor(gameObject, true);
|
||||
break;
|
||||
case GO_ORMOROK_SPHERE:
|
||||
if (GetBossState(DATA_ORMOROK_ORB) != DONE && GetBossState(DATA_ORMOROK_EVENT) == DONE)
|
||||
gameObject->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE);
|
||||
AddDoor(gameObject, true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectRemove(GameObject* gameObject)
|
||||
{
|
||||
switch (gameObject->GetEntry())
|
||||
{
|
||||
case GO_TELESTRA_SPHERE:
|
||||
case GO_ANOMALUS_SPHERE:
|
||||
case GO_ORMOROK_SPHERE:
|
||||
AddDoor(gameObject, false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
case GO_TELESTRA_SPHERE:
|
||||
SetBossState(DATA_TELESTRA_ORB, NOT_STARTED);
|
||||
SetBossState(DATA_TELESTRA_ORB, DONE);
|
||||
break;
|
||||
case GO_ANOMALUS_SPHERE:
|
||||
SetBossState(DATA_ANOMALUS_ORB, NOT_STARTED);
|
||||
SetBossState(DATA_ANOMALUS_ORB, DONE);
|
||||
break;
|
||||
case GO_ORMOROK_SPHERE:
|
||||
SetBossState(DATA_ORMOROK_ORB, NOT_STARTED);
|
||||
SetBossState(DATA_ORMOROK_ORB, DONE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
bool SetBossState(uint32 id, EncounterState state)
|
||||
{
|
||||
if (!InstanceScript::SetBossState(id, state))
|
||||
return false;
|
||||
|
||||
if (state != DONE || id > DATA_ORMOROK_EVENT)
|
||||
return true;
|
||||
|
||||
BossInfo const* bossInfo = GetBossInfo(id + DATA_TELESTRA_ORB);
|
||||
for (DoorSet::const_iterator i = bossInfo->door[DOOR_TYPE_PASSAGE].begin(); i != bossInfo->door[DOOR_TYPE_PASSAGE].end(); ++i)
|
||||
(*i)->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE);
|
||||
return true;
|
||||
}
|
||||
|
||||
std::string GetSaveData()
|
||||
{
|
||||
std::ostringstream saveStream;
|
||||
saveStream << "N E X " << GetBossSaveData();
|
||||
return saveStream.str();
|
||||
}
|
||||
|
||||
void Load(const char* in)
|
||||
{
|
||||
if( !in )
|
||||
return;
|
||||
|
||||
char dataHead1, dataHead2, dataHead3;
|
||||
std::istringstream loadStream(in);
|
||||
loadStream >> dataHead1 >> dataHead2 >> dataHead3;
|
||||
if (dataHead1 == 'N' && dataHead2 == 'E' && dataHead3 == 'X')
|
||||
{
|
||||
for (uint8 i = 0; i < MAX_ENCOUNTERS; ++i)
|
||||
{
|
||||
uint32 tmpState;
|
||||
loadStream >> tmpState;
|
||||
if (tmpState == IN_PROGRESS || tmpState > SPECIAL)
|
||||
tmpState = NOT_STARTED;
|
||||
SetBossState(i, EncounterState(tmpState));
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
enum eFrayer
|
||||
{
|
||||
SPELL_SUMMON_SEED_POD = 52796,
|
||||
SPELL_SEED_POD = 48082,
|
||||
SPELL_AURA_OF_REGENERATION = 52067,
|
||||
SPELL_CRYSTAL_BLOOM = 48058,
|
||||
SPELL_ENSNARE = 48053
|
||||
};
|
||||
|
||||
class npc_crystalline_frayer : public CreatureScript
|
||||
{
|
||||
public:
|
||||
npc_crystalline_frayer() : CreatureScript("npc_crystalline_frayer") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
{
|
||||
return GetInstanceAI<npc_crystalline_frayerAI>(creature);
|
||||
}
|
||||
|
||||
struct npc_crystalline_frayerAI : public ScriptedAI
|
||||
{
|
||||
npc_crystalline_frayerAI(Creature* creature) : ScriptedAI(creature)
|
||||
{
|
||||
}
|
||||
|
||||
bool _allowDeath;
|
||||
uint32 restoreTimer;
|
||||
uint32 abilityTimer1;
|
||||
uint32 abilityTimer2;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
restoreTimer = 0;
|
||||
abilityTimer1 = 0;
|
||||
abilityTimer2 = 30000;
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit*)
|
||||
{
|
||||
_allowDeath = me->GetInstanceScript()->GetBossState(DATA_ORMOROK_EVENT) == DONE;
|
||||
}
|
||||
|
||||
void EnterEvadeMode()
|
||||
{
|
||||
if (me->isRegeneratingHealth())
|
||||
ScriptedAI::EnterEvadeMode();
|
||||
}
|
||||
|
||||
void DamageTaken(Unit*, uint32& damage, DamageEffectType, SpellSchoolMask)
|
||||
{
|
||||
if (damage >= me->GetHealth())
|
||||
{
|
||||
if (!_allowDeath)
|
||||
{
|
||||
me->RemoveAllAuras();
|
||||
me->DeleteThreatList();
|
||||
me->CombatStop(true);
|
||||
damage = 0;
|
||||
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->SetRegeneratingHealth(false);
|
||||
me->CastSpell(me, SPELL_SUMMON_SEED_POD, true);
|
||||
me->CastSpell(me, SPELL_SEED_POD, true);
|
||||
me->CastSpell(me, SPELL_AURA_OF_REGENERATION, false);
|
||||
restoreTimer = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if (restoreTimer)
|
||||
{
|
||||
restoreTimer += diff;
|
||||
if (restoreTimer >= 90*IN_MILLISECONDS)
|
||||
{
|
||||
Talk(0);
|
||||
me->SetRegeneratingHealth(true);
|
||||
restoreTimer = 0;
|
||||
me->SetReactState(REACT_AGGRESSIVE);
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
abilityTimer1 += diff;
|
||||
abilityTimer2 += diff;
|
||||
|
||||
if (abilityTimer1 >= 5000)
|
||||
{
|
||||
me->CastSpell(me->GetVictim(), SPELL_ENSNARE, false);
|
||||
abilityTimer1 = 0;
|
||||
}
|
||||
|
||||
if (abilityTimer2 >= 30000)
|
||||
{
|
||||
me->CastSpell(me->GetVictim(), SPELL_CRYSTAL_BLOOM, false);
|
||||
abilityTimer2 = 0;
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_instance_nexus()
|
||||
{
|
||||
new instance_nexus();
|
||||
new npc_crystalline_frayer();
|
||||
}
|
||||
@@ -1,40 +0,0 @@
|
||||
/*
|
||||
REWRITTEN BY XINEF
|
||||
*/
|
||||
|
||||
#ifndef DEF_NEXUS_H
|
||||
#define DEF_NEXUS_H
|
||||
|
||||
enum eTypes
|
||||
{
|
||||
DATA_MAGUS_TELESTRA_EVENT = 0,
|
||||
DATA_ANOMALUS_EVENT = 1,
|
||||
DATA_ORMOROK_EVENT = 2,
|
||||
DATA_KERISTRASZA_EVENT = 3,
|
||||
DATA_COMMANDER_EVENT = 4,
|
||||
DATA_TELESTRA_ORB = 5,
|
||||
DATA_ANOMALUS_ORB = 6,
|
||||
DATA_ORMOROK_ORB = 7,
|
||||
MAX_ENCOUNTERS = 8
|
||||
};
|
||||
|
||||
enum Npcs
|
||||
{
|
||||
NPC_ALLIANCE_RANGER = 26802,
|
||||
NPC_ALLIANCE_BERSERKER = 26800,
|
||||
NPC_ALLIANCE_COMMANDER = 27949,
|
||||
NPC_ALLIANCE_CLERIC = 26805,
|
||||
NPC_HORDE_RANGER = 26801,
|
||||
NPC_HORDE_BERSERKER = 26799,
|
||||
NPC_HORDE_COMMANDER = 27947,
|
||||
NPC_HORDE_CLERIC = 26803,
|
||||
|
||||
NPC_COMMANDER_STOUTBEARD = 26796,
|
||||
NPC_COMMANDER_KOLURG = 26798,
|
||||
|
||||
GO_TELESTRA_SPHERE = 188526,
|
||||
GO_ANOMALUS_SPHERE = 188527,
|
||||
GO_ORMOROK_SPHERE = 188528
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,249 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "oculus.h"
|
||||
|
||||
enum Spells
|
||||
{
|
||||
SPELL_MAGIC_PULL = 51336,
|
||||
SPELL_THUNDERING_STOMP_N = 50774,
|
||||
SPELL_THUNDERING_STOMP_H = 59370,
|
||||
|
||||
SPELL_UNSTABLE_SPHERE_PASSIVE = 50756,
|
||||
SPELL_UNSTABLE_SPHERE_PULSE = 50757,
|
||||
SPELL_UNSTABLE_SPHERE_TIMER = 50758,
|
||||
SPELL_TELEPORT_VISUAL = 52096,
|
||||
};
|
||||
|
||||
enum DrakosNPCs
|
||||
{
|
||||
NPC_UNSTABLE_SPHERE = 28166,
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_MAGIC_PULL = 1,
|
||||
EVENT_THUNDERING_STOMP = 2,
|
||||
EVENT_SUMMON = 3,
|
||||
EVENT_SUMMON_x4 = 4,
|
||||
};
|
||||
|
||||
#define SPELL_THUNDERING_STOMP DUNGEON_MODE(SPELL_THUNDERING_STOMP_N, SPELL_THUNDERING_STOMP_H)
|
||||
|
||||
enum Yells
|
||||
{
|
||||
SAY_AGGRO = 0,
|
||||
SAY_KILL = 1,
|
||||
SAY_DEATH = 2,
|
||||
SAY_PULL = 3,
|
||||
SAY_STOMP = 4
|
||||
};
|
||||
|
||||
class boss_drakos : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_drakos() : CreatureScript("boss_drakos") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* pCreature) const
|
||||
{
|
||||
return new boss_drakosAI (pCreature);
|
||||
}
|
||||
|
||||
struct boss_drakosAI : public ScriptedAI
|
||||
{
|
||||
boss_drakosAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
|
||||
InstanceScript* pInstance;
|
||||
EventMap events;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
if (pInstance)
|
||||
pInstance->SetData(DATA_DRAKOS, NOT_STARTED);
|
||||
|
||||
events.Reset();
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
{
|
||||
Talk(SAY_AGGRO);
|
||||
|
||||
if (pInstance)
|
||||
pInstance->SetData(DATA_DRAKOS, IN_PROGRESS);
|
||||
|
||||
me->SetInCombatWithZone();
|
||||
|
||||
events.RescheduleEvent(EVENT_MAGIC_PULL, urand(10000,15000));
|
||||
events.RescheduleEvent(EVENT_THUNDERING_STOMP, urand(3000, 6000));
|
||||
events.RescheduleEvent(EVENT_SUMMON, 2000);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
Talk(SAY_DEATH);
|
||||
|
||||
if (pInstance)
|
||||
{
|
||||
pInstance->SetData(DATA_DRAKOS, DONE);
|
||||
for( uint8 i=0; i<3; ++i )
|
||||
if( uint64 guid = pInstance->GetData64(DATA_DCD_1+i) )
|
||||
if( GameObject* pGo = ObjectAccessor::GetGameObject(*me, guid) )
|
||||
if( pGo->GetGoState() != GO_STATE_ACTIVE )
|
||||
{
|
||||
pGo->SetLootState(GO_READY);
|
||||
pGo->UseDoorOrButton(0, false);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void KilledUnit(Unit *victim)
|
||||
{
|
||||
Talk(SAY_KILL);
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
void JustSummoned(Creature* summon) {}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if( !UpdateVictim() )
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
|
||||
if( me->HasUnitState(UNIT_STATE_CASTING) )
|
||||
return;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
switch( events.GetEvent() )
|
||||
{
|
||||
case 0:
|
||||
break;
|
||||
case EVENT_MAGIC_PULL:
|
||||
{
|
||||
Talk(SAY_PULL);
|
||||
//me->MonsterTextEmote(TEXT_MAGIC_PULL, 0, true);
|
||||
|
||||
me->CastSpell(me, SPELL_MAGIC_PULL, false);
|
||||
events.RepeatEvent(urand(15000,25000));
|
||||
events.ScheduleEvent(EVENT_SUMMON_x4, 1500);
|
||||
}
|
||||
break;
|
||||
case EVENT_THUNDERING_STOMP:
|
||||
{
|
||||
Talk(SAY_STOMP);
|
||||
|
||||
me->CastSpell(me, SPELL_THUNDERING_STOMP, false);
|
||||
events.RepeatEvent(urand(10000,20000));
|
||||
}
|
||||
break;
|
||||
case EVENT_SUMMON:
|
||||
{
|
||||
for( uint8 i=0; i<2; ++i )
|
||||
{
|
||||
float angle = rand_norm()*2*M_PI;
|
||||
me->SummonCreature(NPC_UNSTABLE_SPHERE, me->GetPositionX() + 5.0f*cos(angle), me->GetPositionY() + 5.0f*sin(angle), me->GetPositionZ(), 0.0f, TEMPSUMMON_TIMED_DESPAWN, 18000);
|
||||
}
|
||||
events.RepeatEvent(2000);
|
||||
}
|
||||
break;
|
||||
case EVENT_SUMMON_x4:
|
||||
for( uint8 i=0; i<4; ++i )
|
||||
{
|
||||
float angle = rand_norm()*2*M_PI;
|
||||
me->SummonCreature(NPC_UNSTABLE_SPHERE, me->GetPositionX() + 5.0f*cos(angle), me->GetPositionY() + 5.0f*sin(angle), me->GetPositionZ(), 0.0f, TEMPSUMMON_TIMED_DESPAWN, 18000);
|
||||
}
|
||||
events.PopEvent();
|
||||
break;
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
class npc_oculus_unstable_sphere : public CreatureScript
|
||||
{
|
||||
public:
|
||||
npc_oculus_unstable_sphere() : CreatureScript("npc_oculus_unstable_sphere") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* pCreature) const
|
||||
{
|
||||
return new npc_oculus_unstable_sphereAI (pCreature);
|
||||
}
|
||||
|
||||
struct npc_oculus_unstable_sphereAI : public ScriptedAI
|
||||
{
|
||||
npc_oculus_unstable_sphereAI(Creature *c) : ScriptedAI(c) {}
|
||||
|
||||
uint32 timer;
|
||||
bool located, gonext;
|
||||
|
||||
void PickNewLocation()
|
||||
{
|
||||
float dist = rand_norm()*40.0f;
|
||||
float angle = rand_norm()*2*M_PI;
|
||||
me->GetMotionMaster()->MovePoint(1, 961.29f + dist*cos(angle), 1049.0f + dist*sin(angle), 360.0f);
|
||||
}
|
||||
|
||||
void MovementInform(uint32 type, uint32 id)
|
||||
{
|
||||
if( type != POINT_MOTION_TYPE || id != 1 )
|
||||
return;
|
||||
|
||||
if( !located )
|
||||
gonext = true;
|
||||
}
|
||||
|
||||
void Reset()
|
||||
{
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
me->SetSpeed(MOVE_RUN, 1.4f, true);
|
||||
me->CastSpell(me, SPELL_UNSTABLE_SPHERE_PASSIVE, true);
|
||||
me->CastSpell(me, SPELL_UNSTABLE_SPHERE_TIMER, true);
|
||||
timer = 0;
|
||||
located = false;
|
||||
gonext = false;
|
||||
|
||||
PickNewLocation();
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who) {}
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if( timer == 0 )
|
||||
me->CastSpell(me, SPELL_TELEPORT_VISUAL, true);
|
||||
|
||||
timer += diff;
|
||||
|
||||
if( timer > 10000 )
|
||||
{
|
||||
if( !located )
|
||||
me->GetMotionMaster()->MoveIdle();
|
||||
located = true;
|
||||
me->CastSpell(me, SPELL_UNSTABLE_SPHERE_PULSE, true);
|
||||
timer -= 2000;
|
||||
}
|
||||
|
||||
if( !located && gonext )
|
||||
{
|
||||
PickNewLocation();
|
||||
gonext = false;
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_boss_drakos()
|
||||
{
|
||||
new boss_drakos();
|
||||
new npc_oculus_unstable_sphere();
|
||||
}
|
||||
@@ -1,241 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "oculus.h"
|
||||
|
||||
enum Spells
|
||||
{
|
||||
SPELL_ARCANE_BARRAGE_N = 50804,
|
||||
SPELL_ARCANE_BARRAGE_H = 59381,
|
||||
SPELL_ARCANE_VOLLEY_N = 51153,
|
||||
SPELL_ARCANE_VOLLEY_H = 59382,
|
||||
SPELL_ENRAGED_ASSAULT = 51170,
|
||||
SPELL_PLANAR_ANOMALIES = 57959,
|
||||
SPELL_PLANAR_SHIFT = 51162,
|
||||
|
||||
SPELL_PLANAR_AURA_DAMAGE = 59379,
|
||||
SPELL_PLANAR_AURA_VISUAL = 57971,
|
||||
SPELL_PLANAR_BLAST = 57976,
|
||||
SPELL_SUMMON_PLANAR_ANOMALY = 57963,
|
||||
|
||||
SPELL_DRAKE_STOP_TIME = 49838,
|
||||
};
|
||||
|
||||
#define SPELL_ARCANE_BARRAGE DUNGEON_MODE(SPELL_ARCANE_BARRAGE_N, SPELL_ARCANE_BARRAGE_H)
|
||||
#define SPELL_ARCANE_VOLLEY DUNGEON_MODE(SPELL_ARCANE_VOLLEY_N, SPELL_ARCANE_VOLLEY_H)
|
||||
|
||||
enum VarosNPCs
|
||||
{
|
||||
NPC_LEY_GUARDIAN_WHELP = 28276,
|
||||
NPC_PLANAR_ANOMALY = 30879,
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_SPELL_ARCANE_BARRAGE = 1,
|
||||
EVENT_SPELL_ARCANE_VOLLEY = 2,
|
||||
EVENT_SPELL_ENRAGED_ASSAULT = 3,
|
||||
EVENT_SPELL_PLANAR_SHIFT = 4,
|
||||
EVENT_SUMMON_WHELPS = 5,
|
||||
EVENT_SUMMON_SINGLE_WHELP = 6,
|
||||
};
|
||||
|
||||
enum Says
|
||||
{
|
||||
SAY_SPAWN = 0,
|
||||
SAY_AGGRO = 1,
|
||||
SAY_ENRAGE = 2,
|
||||
SAY_KILL = 3,
|
||||
SAY_DEATH = 4,
|
||||
SAY_SHIELD = 5,
|
||||
};
|
||||
|
||||
class boss_eregos : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_eregos() : CreatureScript("boss_eregos") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* pCreature) const
|
||||
{
|
||||
return new boss_eregosAI (pCreature);
|
||||
}
|
||||
|
||||
struct boss_eregosAI : public ScriptedAI
|
||||
{
|
||||
boss_eregosAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
|
||||
InstanceScript* pInstance;
|
||||
EventMap events;
|
||||
uint8 shiftNumber;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
if (pInstance)
|
||||
{
|
||||
pInstance->SetData(DATA_EREGOS, NOT_STARTED);
|
||||
if( pInstance->GetData(DATA_UROM) != DONE )
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
else
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
}
|
||||
|
||||
events.Reset();
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
{
|
||||
Talk(SAY_AGGRO);
|
||||
|
||||
if (pInstance)
|
||||
{
|
||||
pInstance->SetData(DATA_EREGOS, IN_PROGRESS);
|
||||
|
||||
if( me->FindNearestCreature(NPC_AMBER_DRAKE, 750.0f, true) )
|
||||
pInstance->SetData(DATA_AMBER_VOID, 0);
|
||||
else
|
||||
pInstance->SetData(DATA_AMBER_VOID, 1);
|
||||
|
||||
if( me->FindNearestCreature(NPC_EMERALD_DRAKE, 750.0f, true) )
|
||||
pInstance->SetData(DATA_EMERALD_VOID, 0);
|
||||
else
|
||||
pInstance->SetData(DATA_EMERALD_VOID, 1);
|
||||
|
||||
if( me->FindNearestCreature(NPC_RUBY_DRAKE, 750.0f, true) )
|
||||
pInstance->SetData(DATA_RUBY_VOID, 0);
|
||||
else
|
||||
pInstance->SetData(DATA_RUBY_VOID, 1);
|
||||
}
|
||||
|
||||
me->SetInCombatWithZone();
|
||||
|
||||
shiftNumber = 0;
|
||||
|
||||
events.RescheduleEvent(EVENT_SPELL_ARCANE_BARRAGE, 0);
|
||||
events.RescheduleEvent(EVENT_SPELL_ARCANE_VOLLEY, 5000);
|
||||
events.RescheduleEvent(EVENT_SPELL_ENRAGED_ASSAULT, 35000);
|
||||
events.RescheduleEvent(EVENT_SUMMON_WHELPS, 40000);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
Talk(SAY_DEATH);
|
||||
|
||||
if (pInstance)
|
||||
pInstance->SetData(DATA_EREGOS, DONE);
|
||||
|
||||
me->SummonGameObject(GO_SPOTLIGHT, 1018.06f, 1051.09f, 605.619019f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0);
|
||||
}
|
||||
|
||||
void DamageTaken(Unit*, uint32 &damage, DamageEffectType, SpellSchoolMask)
|
||||
{
|
||||
if( !me->GetMap()->IsHeroic() )
|
||||
return;
|
||||
|
||||
if( shiftNumber <= uint32(1) && uint32(me->GetHealth()*100/me->GetMaxHealth()) <= uint32(60-shiftNumber*40) )
|
||||
{
|
||||
++shiftNumber;
|
||||
events.RescheduleEvent(EVENT_SPELL_PLANAR_SHIFT, 0);
|
||||
}
|
||||
}
|
||||
|
||||
void KilledUnit(Unit *victim)
|
||||
{
|
||||
Talk(SAY_KILL);
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
|
||||
void JustSummoned(Creature* pSummon)
|
||||
{
|
||||
if( pSummon->GetEntry() != NPC_LEY_GUARDIAN_WHELP )
|
||||
return;
|
||||
|
||||
DoZoneInCombat(pSummon, 300.0f);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if( !UpdateVictim() )
|
||||
return;
|
||||
|
||||
if( me->HasAura(SPELL_PLANAR_SHIFT) || me->HasAura(SPELL_DRAKE_STOP_TIME) )
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
|
||||
if( me->HasUnitState(UNIT_STATE_CASTING) )
|
||||
return;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
switch( events.GetEvent() )
|
||||
{
|
||||
case 0:
|
||||
break;
|
||||
case EVENT_SPELL_ARCANE_BARRAGE:
|
||||
if( Unit* v = me->GetVictim() )
|
||||
me->CastSpell(v, SPELL_ARCANE_BARRAGE, false);
|
||||
events.RepeatEvent(2500);
|
||||
break;
|
||||
case EVENT_SPELL_ARCANE_VOLLEY:
|
||||
me->CastSpell(me, SPELL_ARCANE_VOLLEY, false);
|
||||
events.RepeatEvent(8000);
|
||||
break;
|
||||
case EVENT_SPELL_ENRAGED_ASSAULT:
|
||||
Talk(SAY_ENRAGE);
|
||||
me->CastSpell(me, SPELL_ENRAGED_ASSAULT, false);
|
||||
events.RepeatEvent(35000);
|
||||
break;
|
||||
case EVENT_SUMMON_WHELPS:
|
||||
for( uint8 i=0; i<5; ++i )
|
||||
events.ScheduleEvent(EVENT_SUMMON_SINGLE_WHELP, urand(0, 8000));
|
||||
events.RepeatEvent(40000);
|
||||
break;
|
||||
case EVENT_SUMMON_SINGLE_WHELP:
|
||||
{
|
||||
float x = rand_norm()*50.0f-25.0f;
|
||||
float y = rand_norm()*50.0f-25.0f;
|
||||
float z = rand_norm()*50.0f-25.0f;
|
||||
me->SummonCreature(NPC_LEY_GUARDIAN_WHELP, me->GetPositionX()+x, me->GetPositionY()+y, me->GetPositionZ()+z, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
|
||||
events.PopEvent();
|
||||
}
|
||||
break;
|
||||
case EVENT_SPELL_PLANAR_SHIFT:
|
||||
//me->MonsterYell(TEXT_PLANAR_SHIFT_SAY, LANG_UNIVERSAL, 0);
|
||||
Talk(SAY_SHIELD);
|
||||
me->CastSpell(me, SPELL_PLANAR_SHIFT, false);
|
||||
for( uint8 i=0; i<3; ++i )
|
||||
if( Unit* t = SelectTarget(SELECT_TARGET_RANDOM, 0, 300.0f, false) )
|
||||
if( Creature* pa = me->SummonCreature(NPC_PLANAR_ANOMALY, *me, TEMPSUMMON_TIMED_DESPAWN, 17000) )
|
||||
{
|
||||
pa->SetCanFly(true);
|
||||
pa->SetDisableGravity(true);
|
||||
pa->SetHover(true);
|
||||
pa->SendMovementFlagUpdate();
|
||||
pa->CastSpell(pa, SPELL_PLANAR_AURA_VISUAL, true);
|
||||
pa->CastSpell(pa, SPELL_PLANAR_AURA_DAMAGE, true);
|
||||
if (Aura* a = pa->GetAura(SPELL_PLANAR_AURA_DAMAGE))
|
||||
a->SetDuration(15000);
|
||||
if( pa->AI() )
|
||||
{
|
||||
pa->AI()->AttackStart(t);
|
||||
pa->GetMotionMaster()->MoveChase(t, 0.01f);
|
||||
}
|
||||
}
|
||||
events.PopEvent();
|
||||
break;
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_boss_eregos()
|
||||
{
|
||||
new boss_eregos();
|
||||
}
|
||||
@@ -1,353 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "oculus.h"
|
||||
#include "SpellInfo.h"
|
||||
|
||||
enum Spells
|
||||
{
|
||||
SPELL_EVOCATION = 51602,
|
||||
SPELL_SUMMON_MENAGERIE_1 = 50476,
|
||||
SPELL_SUMMON_MENAGERIE_2 = 50495,
|
||||
SPELL_SUMMON_MENAGERIE_3 = 50496,
|
||||
SPELL_TELEPORT = 51112,
|
||||
|
||||
SPELL_FROSTBOMB = 51103,
|
||||
SPELL_TIME_BOMB_N = 51121,
|
||||
SPELL_TIME_BOMB_H = 59376,
|
||||
SPELL_EMPOWERED_ARCANE_EXPLOSION_N = 51110,
|
||||
SPELL_EMPOWERED_ARCANE_EXPLOSION_H = 59377,
|
||||
};
|
||||
|
||||
#define SPELL_EMPOWERED_ARCANE_EXPLOSION DUNGEON_MODE(SPELL_EMPOWERED_ARCANE_EXPLOSION_N, SPELL_EMPOWERED_ARCANE_EXPLOSION_H)
|
||||
#define SPELL_TIME_BOMB DUNGEON_MODE(SPELL_TIME_BOMB_N, SPELL_TIME_BOMB_H)
|
||||
|
||||
enum UromNPCs
|
||||
{
|
||||
NPC_PHANTASMAL_CLOUDSCRAPER = 27645,
|
||||
NPC_PHANTASMAL_MAMMOTH = 27642,
|
||||
NPC_PHANTASMAL_WOLF = 27644,
|
||||
|
||||
NPC_PHANTASMAL_AIR = 27650,
|
||||
NPC_PHANTASMAL_FIRE = 27651,
|
||||
NPC_PHANTASMAL_WATER = 27653,
|
||||
|
||||
NPC_PHANTASMAL_MURLOC = 27649,
|
||||
NPC_PHANTASMAL_NAGAL = 27648,
|
||||
NPC_PHANTASMAL_OGRE = 27647,
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_FROSTBOMB = 1,
|
||||
EVENT_TELEPORT_TO_CENTER = 2,
|
||||
EVENT_TELE_BACK = 3,
|
||||
EVENT_TIME_BOMB = 4,
|
||||
};
|
||||
|
||||
enum Yells
|
||||
{
|
||||
SAY_SUMMON_1 = 0,
|
||||
SAY_SUMMON_2 = 1,
|
||||
SAY_SUMMON_3 = 2,
|
||||
SAY_AGGRO = 3,
|
||||
EMOTE_ARCANE_EXPLOSION = 4,
|
||||
SAY_ARCANE_EXPLOSION = 5,
|
||||
SAY_DEATH = 6,
|
||||
SAY_PLAYER_KILL = 7
|
||||
};
|
||||
|
||||
float summons[3][4] = {
|
||||
{NPC_PHANTASMAL_AIR, NPC_PHANTASMAL_AIR, NPC_PHANTASMAL_WATER, NPC_PHANTASMAL_FIRE},
|
||||
{NPC_PHANTASMAL_OGRE, NPC_PHANTASMAL_OGRE, NPC_PHANTASMAL_NAGAL, NPC_PHANTASMAL_MURLOC},
|
||||
{NPC_PHANTASMAL_CLOUDSCRAPER, NPC_PHANTASMAL_CLOUDSCRAPER, NPC_PHANTASMAL_MAMMOTH, NPC_PHANTASMAL_WOLF}
|
||||
};
|
||||
|
||||
float cords[4][4] = {
|
||||
{1177.47f, 937.722f, 527.405f, 2.21657f},
|
||||
{968.66f, 1042.53f, 527.32f, 0.077f},
|
||||
{1164.02f, 1170.85f, 527.321f, 3.66f},
|
||||
{1118.31f, 1080.377f, 508.361f, 4.25f}
|
||||
};
|
||||
|
||||
class boss_urom : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_urom() : CreatureScript("boss_urom") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* pCreature) const
|
||||
{
|
||||
return new boss_uromAI (pCreature);
|
||||
}
|
||||
|
||||
struct boss_uromAI : public ScriptedAI
|
||||
{
|
||||
boss_uromAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
|
||||
InstanceScript* pInstance;
|
||||
EventMap events;
|
||||
bool lock;
|
||||
float x,y,z;
|
||||
int32 releaseLockTimer;
|
||||
|
||||
uint8 GetPhaseByCurrentPosition()
|
||||
{
|
||||
for (uint8 i=0; i<4; ++i)
|
||||
if (me->GetDistance(cords[i][0], cords[i][1], cords[i][2]) < 20.0f)
|
||||
return i;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void Reset()
|
||||
{
|
||||
if (pInstance)
|
||||
{
|
||||
pInstance->SetData(DATA_UROM, NOT_STARTED);
|
||||
if( pInstance->GetData(DATA_VAROS) != DONE )
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
else
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
}
|
||||
|
||||
me->CastSpell(me, SPELL_EVOCATION, true);
|
||||
events.Reset();
|
||||
lock = false;
|
||||
x,y,z = 0.0f;
|
||||
releaseLockTimer = 0;
|
||||
me->ApplySpellImmune(0, IMMUNITY_ID, 49838, true);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
{
|
||||
if( lock )
|
||||
return;
|
||||
|
||||
uint8 phase = GetPhaseByCurrentPosition();
|
||||
if( phase == 3 )
|
||||
{
|
||||
Talk(SAY_AGGRO);
|
||||
|
||||
if( pInstance )
|
||||
pInstance->SetData(DATA_UROM, IN_PROGRESS);
|
||||
|
||||
me->SetInCombatWithZone();
|
||||
me->SetHomePosition(cords[0][0], cords[0][1], cords[0][2], cords[0][3]);
|
||||
if( me->FindCurrentSpellBySpellId(SPELL_EVOCATION) )
|
||||
me->InterruptNonMeleeSpells(false);
|
||||
|
||||
events.RescheduleEvent(EVENT_FROSTBOMB, urand(7000, 11000));
|
||||
events.RescheduleEvent(EVENT_TELEPORT_TO_CENTER, urand(30000, 35000));
|
||||
events.RescheduleEvent(EVENT_TIME_BOMB, urand(20000, 25000));
|
||||
}
|
||||
else
|
||||
{
|
||||
lock = true;
|
||||
|
||||
switch( phase )
|
||||
{
|
||||
case 0:
|
||||
Talk(SAY_SUMMON_1);
|
||||
me->InterruptNonMeleeSpells(false);
|
||||
me->CastSpell(me, SPELL_SUMMON_MENAGERIE_1, false);
|
||||
break;
|
||||
case 1:
|
||||
Talk(SAY_SUMMON_2);
|
||||
me->InterruptNonMeleeSpells(false);
|
||||
me->CastSpell(me, SPELL_SUMMON_MENAGERIE_2, false);
|
||||
break;
|
||||
case 2:
|
||||
Talk(SAY_SUMMON_3);
|
||||
me->InterruptNonMeleeSpells(false);
|
||||
me->CastSpell(me, SPELL_SUMMON_MENAGERIE_3, false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who)
|
||||
{
|
||||
if( lock )
|
||||
return;
|
||||
|
||||
if (me->GetDistance(1103.0f, 1049.0f, 510.0f) < 55.0f)
|
||||
ScriptedAI::AttackStart(who);
|
||||
}
|
||||
|
||||
void JustSummoned(Creature* pSummon)
|
||||
{
|
||||
pSummon->SetInCombatWithZone();
|
||||
if( Unit* v = pSummon->SelectVictim() )
|
||||
if( pSummon->AI() )
|
||||
pSummon->AI()->AttackStart(v);
|
||||
}
|
||||
|
||||
void LeaveCombat()
|
||||
{
|
||||
me->RemoveAllAuras();
|
||||
me->DeleteThreatList();
|
||||
me->CombatStop(true);
|
||||
me->LoadCreaturesAddon(true);
|
||||
me->SetLootRecipient(NULL);
|
||||
me->ResetPlayerDamageReq();
|
||||
}
|
||||
|
||||
void JustDied(Unit* /*killer*/)
|
||||
{
|
||||
Talk(SAY_DEATH);
|
||||
|
||||
if (pInstance)
|
||||
pInstance->SetData(DATA_UROM, DONE);
|
||||
}
|
||||
|
||||
void KilledUnit(Unit* /*victim*/)
|
||||
{
|
||||
Talk(SAY_PLAYER_KILL);
|
||||
}
|
||||
|
||||
void SpellHit(Unit* /*caster*/, const SpellInfo* spell)
|
||||
{
|
||||
switch( spell->Id )
|
||||
{
|
||||
case SPELL_SUMMON_MENAGERIE_1:
|
||||
{
|
||||
for( uint8 i=0; i<4; ++i )
|
||||
me->SummonCreature(summons[0][i], cords[0][0] + ((i%2) ? 4.0f : -4.0f), cords[0][1] + (i<2 ? 4.0f : -4.0f), cords[0][2], 0.0f, TEMPSUMMON_TIMED_DESPAWN, 300000);
|
||||
uint8 phase = GetPhaseByCurrentPosition();
|
||||
me->SetHomePosition(cords[phase+1][0], cords[phase+1][1], cords[phase+1][2], cords[phase+1][3]);
|
||||
me->DestroyForNearbyPlayers();
|
||||
LeaveCombat();
|
||||
me->CastSpell(me, SPELL_EVOCATION, true);
|
||||
releaseLockTimer = 1;
|
||||
}
|
||||
break;
|
||||
case SPELL_SUMMON_MENAGERIE_2:
|
||||
{
|
||||
for( uint8 i=0; i<4; ++i )
|
||||
me->SummonCreature(summons[1][i], cords[1][0] + ((i%2) ? 4.0f : -4.0f), cords[1][1] + (i<2 ? 4.0f : -4.0f), cords[1][2], 0.0f, TEMPSUMMON_TIMED_DESPAWN, 300000);
|
||||
uint8 phase = GetPhaseByCurrentPosition();
|
||||
me->SetHomePosition(cords[phase+1][0], cords[phase+1][1], cords[phase+1][2], cords[phase+1][3]);
|
||||
me->DestroyForNearbyPlayers();
|
||||
LeaveCombat();
|
||||
me->CastSpell(me, SPELL_EVOCATION, true);
|
||||
releaseLockTimer = 1;
|
||||
}
|
||||
break;
|
||||
case SPELL_SUMMON_MENAGERIE_3:
|
||||
{
|
||||
for( uint8 i=0; i<4; ++i )
|
||||
me->SummonCreature(summons[2][i], cords[2][0] + ((i%2) ? 4.0f : -4.0f), cords[2][1] + (i<2 ? 4.0f : -4.0f), cords[2][2], 0.0f, TEMPSUMMON_TIMED_DESPAWN, 300000);
|
||||
uint8 phase = GetPhaseByCurrentPosition();
|
||||
me->SetHomePosition(cords[phase+1][0], cords[phase+1][1], cords[phase+1][2], cords[phase+1][3]);
|
||||
me->DestroyForNearbyPlayers();
|
||||
LeaveCombat();
|
||||
me->CastSpell(me, SPELL_EVOCATION, true);
|
||||
releaseLockTimer = 1;
|
||||
}
|
||||
break;
|
||||
case SPELL_TELEPORT:
|
||||
me->GetMotionMaster()->Clear();
|
||||
me->GetMotionMaster()->MoveIdle();
|
||||
me->StopMoving();
|
||||
me->SetControlled(true, UNIT_STATE_ROOT);
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->SetCanFly(true);
|
||||
me->SetDisableGravity(true);
|
||||
me->NearTeleportTo(1103.69f, 1048.76f, 512.279f, 1.16f);
|
||||
|
||||
Talk(SAY_ARCANE_EXPLOSION);
|
||||
Talk(EMOTE_ARCANE_EXPLOSION);
|
||||
|
||||
me->CastSpell(me, SPELL_EMPOWERED_ARCANE_EXPLOSION, false);
|
||||
events.RescheduleEvent(EVENT_TELE_BACK, DUNGEON_MODE(9000, 7000));
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit* /*who*/) {}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if( releaseLockTimer )
|
||||
{
|
||||
if( releaseLockTimer >= 5000 )
|
||||
{
|
||||
lock = false;
|
||||
if (me->IsInCombat())
|
||||
{
|
||||
LeaveCombat();
|
||||
me->CastSpell(me, SPELL_EVOCATION, true);
|
||||
}
|
||||
releaseLockTimer = 0;
|
||||
}
|
||||
else
|
||||
releaseLockTimer += diff;
|
||||
}
|
||||
|
||||
if( !UpdateVictim() )
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
|
||||
if( me->HasUnitState(UNIT_STATE_CASTING) )
|
||||
return;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
switch( events.GetEvent() )
|
||||
{
|
||||
case 0:
|
||||
break;
|
||||
case EVENT_FROSTBOMB:
|
||||
if( Unit* v = me->GetVictim() )
|
||||
me->CastSpell(v, SPELL_FROSTBOMB, false);
|
||||
events.RepeatEvent(urand(7000,11000));
|
||||
break;
|
||||
case EVENT_TIME_BOMB:
|
||||
if( Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 100.0f, true) )
|
||||
me->CastSpell(target, SPELL_TIME_BOMB, false);
|
||||
events.RepeatEvent(urand(20000, 25000));
|
||||
break;
|
||||
case EVENT_TELEPORT_TO_CENTER:
|
||||
x = me->GetPositionX();
|
||||
y = me->GetPositionY();
|
||||
z = me->GetPositionZ();
|
||||
me->CastSpell(me, SPELL_TELEPORT, false);
|
||||
events.RepeatEvent(urand(25000,30000));
|
||||
events.DelayEvents(10000);
|
||||
break;
|
||||
case EVENT_TELE_BACK:
|
||||
me->GetMotionMaster()->MoveIdle();
|
||||
me->DisableSpline();
|
||||
me->SetCanFly(false);
|
||||
me->SetDisableGravity(false);
|
||||
me->NearTeleportTo(x, y, z, 0.0f);
|
||||
me->SetControlled(false, UNIT_STATE_ROOT);
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->GetMotionMaster()->MoveChase(me->GetVictim());
|
||||
events.PopEvent();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void EnterEvadeMode()
|
||||
{
|
||||
me->SetCanFly(false);
|
||||
me->SetDisableGravity(false);
|
||||
me->SetControlled(false, UNIT_STATE_ROOT);
|
||||
ScriptedAI::EnterEvadeMode();
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_boss_urom()
|
||||
{
|
||||
new boss_urom();
|
||||
}
|
||||
@@ -1,240 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "oculus.h"
|
||||
|
||||
enum Spells
|
||||
{
|
||||
SPELL_CORE_AURA_PASSIVE = 50798,
|
||||
|
||||
SPELL_AMPLIFY_MAGIC_N = 51054,
|
||||
SPELL_AMPLIFY_MAGIC_H = 59371,
|
||||
|
||||
SPELL_ENERGIZE_CORES_N = 50785,
|
||||
SPELL_ENERGIZE_CORES_H = 59372,
|
||||
SPELL_ENERGIZE_CORES_THIN_N = 61407,
|
||||
SPELL_ENERGIZE_CORES_THIN_H = 62136,
|
||||
SPELL_ENERGIZE_CORES_TRIGGER_1 = 54069,
|
||||
SPELL_ENERGIZE_CORES_TRIGGER_2 = 56251,
|
||||
|
||||
SPELL_CALL_AZURE_RING_CAPTAIN_1 = 51002,
|
||||
SPELL_CALL_AZURE_RING_CAPTAIN_2 = 51006,
|
||||
SPELL_CALL_AZURE_RING_CAPTAIN_3 = 51007,
|
||||
SPELL_CALL_AZURE_RING_CAPTAIN_4 = 51008,
|
||||
|
||||
SPELL_SUMMON_ARCANE_BEAM_1 = 51014,
|
||||
SPELL_SUMMON_ARCANE_BEAM_2 = 51017,
|
||||
SPELL_ARCANE_BEAM_SPAWN_TRIGGER = 51022,
|
||||
SPELL_ARCANE_BEAM_VISUAL = 51024,
|
||||
SPELL_ARCANE_BEAM_PERIODIC_DAMAGE = 51019,
|
||||
};
|
||||
|
||||
enum VarosNPCs
|
||||
{
|
||||
NPC_CENTRIFUGE_CORE = 28183,
|
||||
NPC_AZURE_RING_CAPTAIN = 28236,
|
||||
NPC_ARCANE_BEAM = 28239,
|
||||
};
|
||||
|
||||
enum Events
|
||||
{
|
||||
EVENT_AMPLIFY_MAGIC = 1,
|
||||
EVENT_CALL_AZURE_RING_CAPTAIN_1 = 2,
|
||||
EVENT_CALL_AZURE_RING_CAPTAIN_2 = 3,
|
||||
EVENT_CALL_AZURE_RING_CAPTAIN_3 = 4,
|
||||
EVENT_CALL_AZURE_RING_CAPTAIN_4 = 5,
|
||||
EVENT_ENERGIZE_CORES_THIN = 6,
|
||||
EVENT_ENERGIZE_CORES_DAMAGE = 7,
|
||||
};
|
||||
|
||||
#define SPELL_AMPLIFY_MAGIC DUNGEON_MODE(SPELL_AMPLIFY_MAGIC_N, SPELL_AMPLIFY_MAGIC_H)
|
||||
#define SPELL_ENERGIZE_CORES DUNGEON_MODE(SPELL_ENERGIZE_CORES_N, SPELL_ENERGIZE_CORES_H)
|
||||
#define SPELL_ENERGIZE_CORES_THIN DUNGEON_MODE(SPELL_ENERGIZE_CORES_THIN_N, SPELL_ENERGIZE_CORES_THIN_H)
|
||||
|
||||
enum Says
|
||||
{
|
||||
SAY_AGGRO = 0,
|
||||
SAY_AZURE = 1,
|
||||
SAY_AZURE_EMOTE = 2,
|
||||
SAY_DEATH = 3
|
||||
};
|
||||
|
||||
class boss_varos : public CreatureScript
|
||||
{
|
||||
public:
|
||||
boss_varos() : CreatureScript("boss_varos") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* pCreature) const
|
||||
{
|
||||
return new boss_varosAI (pCreature);
|
||||
}
|
||||
struct boss_varosAI : public ScriptedAI
|
||||
{
|
||||
boss_varosAI(Creature *c) : ScriptedAI(c)
|
||||
{
|
||||
pInstance = c->GetInstanceScript();
|
||||
}
|
||||
|
||||
InstanceScript* pInstance;
|
||||
EventMap events;
|
||||
float ZapAngle;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
if (pInstance)
|
||||
{
|
||||
pInstance->SetData(DATA_VAROS, NOT_STARTED);
|
||||
if( pInstance->GetData(DATA_CC_COUNT) < 10 )
|
||||
{
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->CastSpell(me, 50053, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->InterruptNonMeleeSpells(false);
|
||||
me->RemoveAura(50053);
|
||||
}
|
||||
}
|
||||
|
||||
events.Reset();
|
||||
ZapAngle = 6.20f;
|
||||
me->ApplySpellImmune(0, IMMUNITY_ID, 49838, true);
|
||||
me->SetControlled(false, UNIT_STATE_ROOT);
|
||||
me->DisableRotate(false);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
{
|
||||
Talk(SAY_AGGRO);
|
||||
|
||||
if (pInstance)
|
||||
pInstance->SetData(DATA_VAROS, IN_PROGRESS);
|
||||
|
||||
me->SetInCombatWithZone();
|
||||
|
||||
events.RescheduleEvent(EVENT_AMPLIFY_MAGIC, urand(5000, 10000));
|
||||
events.RescheduleEvent(EVENT_CALL_AZURE_RING_CAPTAIN_1, 5000);
|
||||
events.RescheduleEvent(EVENT_ENERGIZE_CORES_THIN, 0);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
Talk(SAY_DEATH);
|
||||
|
||||
if (pInstance)
|
||||
{
|
||||
pInstance->SetData(DATA_VAROS, DONE);
|
||||
pInstance->instance->SummonCreature(NPC_IMAGE_OF_BELGARISTRASZ, *me);
|
||||
}
|
||||
}
|
||||
|
||||
void EnterEvadeMode()
|
||||
{
|
||||
me->SetControlled(false, UNIT_STATE_ROOT);
|
||||
me->DisableRotate(false);
|
||||
ScriptedAI::EnterEvadeMode();
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit* who) {}
|
||||
void JustSummoned(Creature* summon) {}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if( !UpdateVictim() )
|
||||
return;
|
||||
|
||||
events.Update(diff);
|
||||
|
||||
if( me->HasUnitState(UNIT_STATE_CASTING) )
|
||||
return;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
switch( events.GetEvent() )
|
||||
{
|
||||
case 0:
|
||||
break;
|
||||
case EVENT_AMPLIFY_MAGIC:
|
||||
{
|
||||
if( Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 50.0f, true) )
|
||||
me->CastSpell(target, SPELL_AMPLIFY_MAGIC, false);
|
||||
events.RepeatEvent(urand(17500, 22500));
|
||||
}
|
||||
break;
|
||||
case EVENT_CALL_AZURE_RING_CAPTAIN_1:
|
||||
case EVENT_CALL_AZURE_RING_CAPTAIN_2:
|
||||
case EVENT_CALL_AZURE_RING_CAPTAIN_3:
|
||||
case EVENT_CALL_AZURE_RING_CAPTAIN_4:
|
||||
{
|
||||
Talk(SAY_AZURE);
|
||||
Talk(SAY_AZURE_EMOTE);
|
||||
switch( events.GetEvent() )
|
||||
{
|
||||
case EVENT_CALL_AZURE_RING_CAPTAIN_1:
|
||||
me->CastSpell(me, SPELL_CALL_AZURE_RING_CAPTAIN_1, true);
|
||||
events.ScheduleEvent(EVENT_CALL_AZURE_RING_CAPTAIN_2, 16000);
|
||||
break;
|
||||
case EVENT_CALL_AZURE_RING_CAPTAIN_2:
|
||||
me->CastSpell(me, SPELL_CALL_AZURE_RING_CAPTAIN_2, true);
|
||||
events.ScheduleEvent(EVENT_CALL_AZURE_RING_CAPTAIN_3, 16000);
|
||||
break;
|
||||
case EVENT_CALL_AZURE_RING_CAPTAIN_3:
|
||||
me->CastSpell(me, SPELL_CALL_AZURE_RING_CAPTAIN_3, true);
|
||||
events.ScheduleEvent(EVENT_CALL_AZURE_RING_CAPTAIN_4, 16000);
|
||||
break;
|
||||
case EVENT_CALL_AZURE_RING_CAPTAIN_4:
|
||||
me->CastSpell(me, SPELL_CALL_AZURE_RING_CAPTAIN_4, true);
|
||||
events.ScheduleEvent(EVENT_CALL_AZURE_RING_CAPTAIN_1, 16000);
|
||||
break;
|
||||
}
|
||||
if( Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 100.0f, true) )
|
||||
{
|
||||
if( Creature* trigger = me->SummonCreature(NPC_ARCANE_BEAM, target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), 0.0f, TEMPSUMMON_TIMED_DESPAWN, 13000) )
|
||||
{
|
||||
if( Creature* c = me->FindNearestCreature(NPC_AZURE_RING_CAPTAIN, 500.0f, true) )
|
||||
c->CastSpell(trigger, SPELL_ARCANE_BEAM_VISUAL, true);
|
||||
trigger->GetMotionMaster()->MoveChase(target, 0.1f);
|
||||
trigger->CastSpell(me, SPELL_ARCANE_BEAM_PERIODIC_DAMAGE, true);
|
||||
}
|
||||
}
|
||||
events.PopEvent();
|
||||
}
|
||||
break;
|
||||
case EVENT_ENERGIZE_CORES_THIN:
|
||||
{
|
||||
me->SetControlled(false, UNIT_STATE_ROOT);
|
||||
me->DisableRotate(false);
|
||||
me->SetOrientation(ZapAngle);
|
||||
me->CastSpell(me, SPELL_ENERGIZE_CORES_THIN, true);
|
||||
events.PopEvent();
|
||||
events.ScheduleEvent(EVENT_ENERGIZE_CORES_DAMAGE, 4500);
|
||||
}
|
||||
break;
|
||||
case EVENT_ENERGIZE_CORES_DAMAGE:
|
||||
{
|
||||
me->SetOrientation(ZapAngle);
|
||||
me->DisableRotate(true);
|
||||
me->DisableSpline();
|
||||
me->SetFacingTo(ZapAngle);
|
||||
me->SetControlled(true, UNIT_STATE_ROOT);
|
||||
me->CastSpell((Unit*)NULL, SPELL_ENERGIZE_CORES, false);
|
||||
ZapAngle += M_PI/2;
|
||||
if( ZapAngle >= 2*M_PI )
|
||||
ZapAngle -= 2*M_PI;
|
||||
events.PopEvent();
|
||||
events.ScheduleEvent(EVENT_ENERGIZE_CORES_THIN, 2000);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_boss_varos()
|
||||
{
|
||||
new boss_varos();
|
||||
}
|
||||
@@ -1,302 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "oculus.h"
|
||||
#include "LFGMgr.h"
|
||||
#include "Group.h"
|
||||
#include "Player.h"
|
||||
|
||||
class instance_oculus : public InstanceMapScript
|
||||
{
|
||||
public:
|
||||
instance_oculus() : InstanceMapScript("instance_oculus", 578) { }
|
||||
|
||||
InstanceScript* GetInstanceScript(InstanceMap* pMap) const
|
||||
{
|
||||
return new instance_oculus_InstanceMapScript(pMap);
|
||||
}
|
||||
|
||||
struct instance_oculus_InstanceMapScript : public InstanceScript
|
||||
{
|
||||
instance_oculus_InstanceMapScript(Map* pMap) : InstanceScript(pMap) { Initialize(); }
|
||||
|
||||
uint32 m_auiEncounter[MAX_ENCOUNTER];
|
||||
uint64 DragonCageDoorGUID[3];
|
||||
uint64 EregosCacheGUID;
|
||||
uint32 CentrifugeCount;
|
||||
|
||||
uint64 uiDrakosGUID;
|
||||
uint64 uiVarosGUID;
|
||||
uint64 uiUromGUID;
|
||||
uint64 uiEregosGUID;
|
||||
|
||||
bool bAmberVoid;
|
||||
bool bEmeraldVoid;
|
||||
bool bRubyVoid;
|
||||
|
||||
void Initialize()
|
||||
{
|
||||
EregosCacheGUID = 0;
|
||||
uiDrakosGUID = 0;
|
||||
uiVarosGUID = 0;
|
||||
uiUromGUID = 0;
|
||||
uiEregosGUID = 0;
|
||||
CentrifugeCount = 0;
|
||||
bAmberVoid = false;
|
||||
bEmeraldVoid = false;
|
||||
bRubyVoid = false;
|
||||
|
||||
memset(&m_auiEncounter, 0, sizeof(m_auiEncounter));
|
||||
memset(&DragonCageDoorGUID, 0, sizeof(DragonCageDoorGUID));
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* pCreature)
|
||||
{
|
||||
switch( pCreature->GetEntry() )
|
||||
{
|
||||
case NPC_DRAKOS:
|
||||
uiDrakosGUID = pCreature->GetGUID();
|
||||
break;
|
||||
case NPC_VAROS:
|
||||
uiVarosGUID = pCreature->GetGUID();
|
||||
break;
|
||||
case NPC_UROM:
|
||||
uiUromGUID = pCreature->GetGUID();
|
||||
break;
|
||||
case NPC_EREGOS:
|
||||
uiEregosGUID = pCreature->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnGameObjectCreate(GameObject* pGo)
|
||||
{
|
||||
switch( pGo->GetEntry() )
|
||||
{
|
||||
case GO_DRAGON_CAGE_DOOR:
|
||||
for( uint8 i=0; i<3; ++i )
|
||||
{
|
||||
if( DragonCageDoorGUID[i] )
|
||||
continue;
|
||||
|
||||
DragonCageDoorGUID[i] = pGo->GetGUID();
|
||||
break;
|
||||
}
|
||||
if( m_auiEncounter[DATA_DRAKOS] == DONE )
|
||||
if( pGo->GetGoState() != GO_STATE_ACTIVE )
|
||||
{
|
||||
pGo->SetLootState(GO_READY);
|
||||
pGo->UseDoorOrButton(0, false);
|
||||
}
|
||||
break;
|
||||
case GO_CACHE_OF_EREGOS:
|
||||
case GO_CACHE_OF_EREGOS_HERO:
|
||||
EregosCacheGUID = pGo->GetGUID();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void OnPlayerEnter(Player* player)
|
||||
{
|
||||
if (m_auiEncounter[DATA_DRAKOS] == DONE && m_auiEncounter[DATA_VAROS] != DONE)
|
||||
{
|
||||
player->SendUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW, 1);
|
||||
player->SendUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_AMOUNT, 10-CentrifugeCount);
|
||||
}
|
||||
else
|
||||
{
|
||||
player->SendUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW, 0);
|
||||
player->SendUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_AMOUNT, 0);
|
||||
}
|
||||
}
|
||||
|
||||
void OnUnitDeath(Unit* unit)
|
||||
{
|
||||
if (unit->GetEntry() == NPC_CENTRIFUGE_CONSTRUCT)
|
||||
SetData(DATA_CC_COUNT, DONE);
|
||||
}
|
||||
|
||||
void SetData(uint32 type, uint32 data)
|
||||
{
|
||||
switch( type )
|
||||
{
|
||||
case DATA_DRAKOS:
|
||||
m_auiEncounter[DATA_DRAKOS] = data;
|
||||
if( data == DONE )
|
||||
{
|
||||
DoUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW, 1);
|
||||
DoUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_AMOUNT, 10-CentrifugeCount);
|
||||
|
||||
if (instance->IsHeroic())
|
||||
DoStartTimedAchievement(ACHIEVEMENT_TIMED_TYPE_EVENT, ACHIEV_MAKE_IT_COUNT_TIMED_EVENT);
|
||||
}
|
||||
break;
|
||||
case DATA_VAROS:
|
||||
m_auiEncounter[DATA_VAROS] = data;
|
||||
if( data == DONE )
|
||||
{
|
||||
DoUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW, 0);
|
||||
|
||||
if( Creature* urom = instance->GetCreature(uiUromGUID) )
|
||||
urom->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
}
|
||||
break;
|
||||
case DATA_UROM:
|
||||
m_auiEncounter[DATA_UROM] = data;
|
||||
if( data == DONE )
|
||||
if( Creature* eregos = instance->GetCreature(uiEregosGUID) )
|
||||
eregos->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
break;
|
||||
case DATA_EREGOS:
|
||||
m_auiEncounter[DATA_EREGOS] = data;
|
||||
if (data == DONE)
|
||||
DoRespawnGameObject(EregosCacheGUID, 7*DAY);
|
||||
break;
|
||||
case DATA_CC_COUNT:
|
||||
if( CentrifugeCount < 10 )
|
||||
{
|
||||
++CentrifugeCount;
|
||||
DoUpdateWorldState(WORLD_STATE_CENTRIFUGE_CONSTRUCT_AMOUNT, 10-CentrifugeCount);
|
||||
}
|
||||
if( CentrifugeCount >= 10 )
|
||||
if( Creature* varos = instance->GetCreature(uiVarosGUID) )
|
||||
{
|
||||
varos->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
varos->InterruptNonMeleeSpells(false);
|
||||
varos->RemoveAura(50053);
|
||||
}
|
||||
break;
|
||||
case DATA_AMBER_VOID:
|
||||
bAmberVoid = data ? true : false;
|
||||
break;
|
||||
case DATA_EMERALD_VOID:
|
||||
bEmeraldVoid = data ? true : false;
|
||||
break;
|
||||
case DATA_RUBY_VOID:
|
||||
bRubyVoid = data ? true : false;
|
||||
break;
|
||||
}
|
||||
|
||||
if( data == DONE )
|
||||
SaveToDB();
|
||||
}
|
||||
|
||||
uint32 GetData(uint32 type) const
|
||||
{
|
||||
switch( type )
|
||||
{
|
||||
case DATA_DRAKOS:
|
||||
case DATA_VAROS:
|
||||
case DATA_UROM:
|
||||
case DATA_EREGOS:
|
||||
return m_auiEncounter[type];
|
||||
case DATA_CC_COUNT:
|
||||
return CentrifugeCount;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
uint64 GetData64(uint32 identifier) const
|
||||
{
|
||||
switch( identifier )
|
||||
{
|
||||
case DATA_DRAKOS:
|
||||
return uiDrakosGUID;
|
||||
case DATA_VAROS:
|
||||
return uiVarosGUID;
|
||||
case DATA_UROM:
|
||||
return uiUromGUID;
|
||||
case DATA_EREGOS:
|
||||
return uiEregosGUID;
|
||||
case DATA_DCD_1:
|
||||
case DATA_DCD_2:
|
||||
case DATA_DCD_3:
|
||||
return DragonCageDoorGUID[identifier-100];
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
std::string GetSaveData()
|
||||
{
|
||||
OUT_SAVE_INST_DATA;
|
||||
|
||||
std::ostringstream saveStream;
|
||||
saveStream << "T O " << m_auiEncounter[0] << ' ' << m_auiEncounter[1] << ' ' << m_auiEncounter[2] << ' ' << m_auiEncounter[3] << ' ' << CentrifugeCount;
|
||||
|
||||
OUT_SAVE_INST_DATA_COMPLETE;
|
||||
return saveStream.str();
|
||||
}
|
||||
|
||||
void Load(const char* in)
|
||||
{
|
||||
if( !in )
|
||||
{
|
||||
OUT_LOAD_INST_DATA_FAIL;
|
||||
return;
|
||||
}
|
||||
|
||||
OUT_LOAD_INST_DATA(in);
|
||||
|
||||
char dataHead1, dataHead2;
|
||||
std::istringstream loadStream(in);
|
||||
loadStream >> dataHead1 >> dataHead2;
|
||||
|
||||
if( dataHead1 == 'T' && dataHead2 == 'O' )
|
||||
{
|
||||
loadStream >> m_auiEncounter[0] >> m_auiEncounter[1] >> m_auiEncounter[2] >> m_auiEncounter[3] >> CentrifugeCount;
|
||||
|
||||
for( uint8 i=0; i<MAX_ENCOUNTER; ++i )
|
||||
if( m_auiEncounter[i] == IN_PROGRESS )
|
||||
m_auiEncounter[i] = NOT_STARTED;
|
||||
|
||||
}
|
||||
else
|
||||
OUT_LOAD_INST_DATA_FAIL;
|
||||
|
||||
OUT_LOAD_INST_DATA_COMPLETE;
|
||||
}
|
||||
|
||||
bool CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* source, Unit const* target = NULL, uint32 miscvalue1 = 0)
|
||||
{
|
||||
switch(criteria_id)
|
||||
{
|
||||
case CRITERIA_EXPERIENCED_AMBER:
|
||||
if( source )
|
||||
if( Unit* drake = source->GetVehicleBase() )
|
||||
if( drake->GetEntry() == NPC_AMBER_DRAKE )
|
||||
return true;
|
||||
break;
|
||||
case CRITERIA_EXPERIENCED_EMERALD:
|
||||
if( source )
|
||||
if( Unit* drake = source->GetVehicleBase() )
|
||||
if( drake->GetEntry() == NPC_EMERALD_DRAKE )
|
||||
return true;
|
||||
break;
|
||||
case CRITERIA_EXPERIENCED_RUBY:
|
||||
if( source )
|
||||
if( Unit* drake = source->GetVehicleBase() )
|
||||
if( drake->GetEntry() == NPC_RUBY_DRAKE )
|
||||
return true;
|
||||
break;
|
||||
case CRITERIA_AMBER_VOID:
|
||||
return bAmberVoid;
|
||||
case CRITERIA_EMERALD_VOID:
|
||||
return bEmeraldVoid;
|
||||
case CRITERIA_RUBY_VOID:
|
||||
return bRubyVoid;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
void AddSC_instance_oculus()
|
||||
{
|
||||
new instance_oculus();
|
||||
}
|
||||
@@ -1,603 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#include "ScriptMgr.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "ScriptedGossip.h"
|
||||
#include "oculus.h"
|
||||
#include "Vehicle.h"
|
||||
#include "CombatAI.h"
|
||||
#include "Player.h"
|
||||
#include "SpellInfo.h"
|
||||
|
||||
enum DrakeGiverTexts
|
||||
{
|
||||
GOSSIP_TEXTID_DRAKES = 13267,
|
||||
GOSSIP_TEXTID_BELGARISTRASZ1 = 12916,
|
||||
GOSSIP_TEXTID_BELGARISTRASZ2 = 13466,
|
||||
GOSSIP_TEXTID_BELGARISTRASZ3 = 13254,
|
||||
GOSSIP_TEXTID_VERDISA1 = 1,
|
||||
GOSSIP_TEXTID_VERDISA2 = 1,
|
||||
GOSSIP_TEXTID_VERDISA3 = 1,
|
||||
GOSSIP_TEXTID_ETERNOS1 = 1,
|
||||
GOSSIP_TEXTID_ETERNOS2 = 1,
|
||||
GOSSIP_TEXTID_ETERNOS3 = 13256,
|
||||
};
|
||||
|
||||
#define GOSSIP_ITEM_DRAKES "So where do we go from here?"
|
||||
#define GOSSIP_ITEM_BELGARISTRASZ1 "I want to fly on the wings of the Red Flight"
|
||||
#define GOSSIP_ITEM_BELGARISTRASZ2 "What abilities do Ruby Drakes have?"
|
||||
#define GOSSIP_ITEM_VERDISA1 "I want to fly on the wings of the Green Flight"
|
||||
#define GOSSIP_ITEM_VERDISA2 "What abilities do Emerald Drakes have?"
|
||||
#define GOSSIP_ITEM_ETERNOS1 "I want to fly on the wings of the Bronze Flight"
|
||||
#define GOSSIP_ITEM_ETERNOS2 "What abilities do Amber Drakes have?"
|
||||
|
||||
#define HAS_ESSENCE(a) ((a)->HasItemCount(ITEM_EMERALD_ESSENCE) || (a)->HasItemCount(ITEM_AMBER_ESSENCE) || (a)->HasItemCount(ITEM_RUBY_ESSENCE))
|
||||
|
||||
|
||||
class npc_oculus_drakegiver : public CreatureScript
|
||||
{
|
||||
public:
|
||||
npc_oculus_drakegiver() : CreatureScript("npc_oculus_drakegiver") { }
|
||||
|
||||
bool OnGossipHello(Player* pPlayer, Creature* pCreature)
|
||||
{
|
||||
if( pCreature->IsQuestGiver() )
|
||||
pPlayer->PrepareQuestMenu(pCreature->GetGUID());
|
||||
|
||||
if( pCreature->GetInstanceScript()->GetData(DATA_DRAKOS) == DONE )
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_DRAKES, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_DRAKES, pCreature->GetGUID());
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool OnGossipSelect(Player* pPlayer, Creature* pCreature, uint32 /*uiSender*/, uint32 uiAction)
|
||||
{
|
||||
pPlayer->PlayerTalkClass->GetGossipMenu().ClearMenu();
|
||||
switch(pCreature->GetEntry())
|
||||
{
|
||||
case NPC_VERDISA:
|
||||
switch(uiAction)
|
||||
{
|
||||
case GOSSIP_ACTION_INFO_DEF + 1:
|
||||
if (!HAS_ESSENCE(pPlayer))
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_VERDISA1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_VERDISA2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_VERDISA1, pCreature->GetGUID());
|
||||
}
|
||||
else
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_VERDISA2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_VERDISA2, pCreature->GetGUID());
|
||||
}
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF + 2:
|
||||
{
|
||||
ItemPosCountVec dest;
|
||||
uint8 msg = pPlayer->CanStoreNewItem(NULL_BAG, NULL_SLOT, dest, ITEM_EMERALD_ESSENCE, 1);
|
||||
if (msg == EQUIP_ERR_OK)
|
||||
pPlayer->StoreNewItem(dest, ITEM_EMERALD_ESSENCE, true);
|
||||
pPlayer->CLOSE_GOSSIP_MENU();
|
||||
break;
|
||||
}
|
||||
case GOSSIP_ACTION_INFO_DEF + 3:
|
||||
if (!HAS_ESSENCE(pPlayer))
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_VERDISA1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_VERDISA3, pCreature->GetGUID());
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case NPC_BELGARISTRASZ:
|
||||
switch(uiAction)
|
||||
{
|
||||
case GOSSIP_ACTION_INFO_DEF + 1:
|
||||
if (!HAS_ESSENCE(pPlayer))
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_BELGARISTRASZ1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_BELGARISTRASZ2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_BELGARISTRASZ1, pCreature->GetGUID());
|
||||
}
|
||||
else
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_BELGARISTRASZ2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_BELGARISTRASZ2, pCreature->GetGUID());
|
||||
}
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF + 2:
|
||||
{
|
||||
ItemPosCountVec dest;
|
||||
uint8 msg = pPlayer->CanStoreNewItem(NULL_BAG, NULL_SLOT, dest, ITEM_RUBY_ESSENCE, 1);
|
||||
if (msg == EQUIP_ERR_OK)
|
||||
pPlayer->StoreNewItem(dest, ITEM_RUBY_ESSENCE, true);
|
||||
pPlayer->CLOSE_GOSSIP_MENU();
|
||||
break;
|
||||
}
|
||||
case GOSSIP_ACTION_INFO_DEF + 3:
|
||||
if (!HAS_ESSENCE(pPlayer))
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_BELGARISTRASZ1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_BELGARISTRASZ3, pCreature->GetGUID());
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case NPC_ETERNOS:
|
||||
switch(uiAction)
|
||||
{
|
||||
case GOSSIP_ACTION_INFO_DEF + 1:
|
||||
if (!HAS_ESSENCE(pPlayer))
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_ETERNOS1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_ETERNOS2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_ETERNOS1, pCreature->GetGUID());
|
||||
}
|
||||
else
|
||||
{
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_ETERNOS2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_ETERNOS2, pCreature->GetGUID());
|
||||
}
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF + 2:
|
||||
{
|
||||
ItemPosCountVec dest;
|
||||
uint8 msg = pPlayer->CanStoreNewItem(NULL_BAG, NULL_SLOT, dest, ITEM_AMBER_ESSENCE, 1);
|
||||
if (msg == EQUIP_ERR_OK)
|
||||
pPlayer->StoreNewItem(dest, ITEM_AMBER_ESSENCE, true);
|
||||
pPlayer->CLOSE_GOSSIP_MENU();
|
||||
break;
|
||||
}
|
||||
case GOSSIP_ACTION_INFO_DEF + 3:
|
||||
if (!HAS_ESSENCE(pPlayer))
|
||||
pPlayer->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_ETERNOS1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXTID_ETERNOS3, pCreature->GetGUID());
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
class npc_oculus_drake : public CreatureScript
|
||||
{
|
||||
public:
|
||||
npc_oculus_drake() : CreatureScript("npc_oculus_drake") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* pCreature) const
|
||||
{
|
||||
return new npc_oculus_drakeAI (pCreature);
|
||||
}
|
||||
|
||||
struct npc_oculus_drakeAI : public VehicleAI
|
||||
{
|
||||
npc_oculus_drakeAI(Creature *pCreature) : VehicleAI(pCreature)
|
||||
{
|
||||
m_pInstance = me->GetInstanceScript();
|
||||
JustSummoned = true;
|
||||
}
|
||||
|
||||
InstanceScript* m_pInstance;
|
||||
bool JustSummoned;
|
||||
uint16 despawnTimer;
|
||||
|
||||
void PassengerBoarded(Unit* who, int8 seatid, bool add)
|
||||
{
|
||||
if (add)
|
||||
{
|
||||
me->SetDisableGravity(false);
|
||||
me->SendMovementFlagUpdate();
|
||||
despawnTimer = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
me->SetHomePosition(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation());
|
||||
me->DisappearAndDie();
|
||||
me->DespawnOrUnsummon(1);
|
||||
}
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
{
|
||||
me->SetHomePosition(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation());
|
||||
me->DisappearAndDie();
|
||||
me->DespawnOrUnsummon(1);
|
||||
}
|
||||
|
||||
void SpellHitTarget(Unit* target, SpellInfo const* spell)
|
||||
{
|
||||
for( uint8 i = 0; i < 8; ++i )
|
||||
if( me->m_spells[i] == spell->Id )
|
||||
{
|
||||
if( target && target->IsAlive() && !target->CanFly() && target->IsHostileTo(me) && !spell->IsTargetingArea())
|
||||
{
|
||||
me->SetHomePosition(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation());
|
||||
if( Unit* charmer = me->GetCharmer() )
|
||||
Unit::Kill(charmer, charmer, false);
|
||||
me->DisappearAndDie();
|
||||
me->DespawnOrUnsummon(1);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
{
|
||||
if( JustSummoned )
|
||||
{
|
||||
despawnTimer = 1;
|
||||
JustSummoned = false;
|
||||
if( m_pInstance )
|
||||
{
|
||||
if( !m_pInstance->IsEncounterInProgress() || m_pInstance->GetData(DATA_EREGOS)==IN_PROGRESS )
|
||||
{
|
||||
if( me->GetVehicleKit() && me->IsSummon() )
|
||||
if( !me->GetVehicleKit()->GetPassenger(0) )
|
||||
{
|
||||
TempSummon* ts = (TempSummon*)me;
|
||||
if( Unit* summoner = ts->GetSummoner() )
|
||||
{
|
||||
if( m_pInstance->GetData(DATA_UROM) == DONE )
|
||||
{
|
||||
switch( me->GetEntry() )
|
||||
{
|
||||
case 27692:
|
||||
me->m_spells[5] = 50344;
|
||||
break;
|
||||
case 27755:
|
||||
me->m_spells[5] = 49592;
|
||||
break;
|
||||
case 27756:
|
||||
me->m_spells[5] = 50253;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
uint32 spell = 0;
|
||||
switch (me->GetEntry())
|
||||
{
|
||||
case 27692: spell = 49427; break;
|
||||
case 27755: spell = 49459; break;
|
||||
case 27756: spell = 49463; break;
|
||||
}
|
||||
|
||||
//summoner->EnterVehicle(me);
|
||||
if (spell)
|
||||
me->CastSpell(summoner, spell, true);
|
||||
me->SetCanFly(true);
|
||||
me->SetSpeed(MOVE_FLIGHT, me->GetSpeedRate(MOVE_RUN), true);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
me->SetHomePosition(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation());
|
||||
me->DisappearAndDie();
|
||||
me->DespawnOrUnsummon(1);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (despawnTimer)
|
||||
{
|
||||
if (despawnTimer >= 5000)
|
||||
{
|
||||
despawnTimer = 0;
|
||||
me->SetHomePosition(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation());
|
||||
me->DisappearAndDie();
|
||||
me->DespawnOrUnsummon(1);
|
||||
return;
|
||||
}
|
||||
else
|
||||
despawnTimer += diff;
|
||||
}
|
||||
|
||||
VehicleAI::UpdateAI(diff);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
enum oculusSpells
|
||||
{
|
||||
SPELL_AMBER_SHOCK_CHARGE = 49836,
|
||||
SPELL_RUBY_EVASIVE_CHARGES = 50241,
|
||||
};
|
||||
|
||||
// 49838 - Stop Time
|
||||
class spell_oculus_stop_time : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_oculus_stop_time() : SpellScriptLoader("spell_oculus_stop_time") { }
|
||||
|
||||
class spell_oculus_stop_time_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_oculus_stop_time_AuraScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/)
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(SPELL_AMBER_SHOCK_CHARGE))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void Apply(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
|
||||
{
|
||||
Unit* caster = GetCaster();
|
||||
if (!caster)
|
||||
return;
|
||||
|
||||
Unit* target = GetTarget();
|
||||
for (uint32 i = 0; i < 5; ++i)
|
||||
caster->CastSpell(target, SPELL_AMBER_SHOCK_CHARGE, true);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
AfterEffectApply += AuraEffectApplyFn(spell_oculus_stop_time_AuraScript::Apply, EFFECT_0, SPELL_AURA_MOD_STUN, AURA_EFFECT_HANDLE_REAL);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_oculus_stop_time_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 50240 - Evasive Maneuvers
|
||||
class spell_oculus_evasive_maneuvers : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_oculus_evasive_maneuvers() : SpellScriptLoader("spell_oculus_evasive_maneuvers") { }
|
||||
|
||||
class spell_oculus_evasive_maneuvers_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_oculus_evasive_maneuvers_AuraScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/)
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(SPELL_RUBY_EVASIVE_CHARGES))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void HandleProc(AuraEffect const* /*aurEff*/, ProcEventInfo& /*eventInfo*/)
|
||||
{
|
||||
PreventDefaultAction();
|
||||
GetTarget()->RemoveAuraFromStack(SPELL_RUBY_EVASIVE_CHARGES);
|
||||
if (!GetTarget()->HasAura(SPELL_RUBY_EVASIVE_CHARGES))
|
||||
SetDuration(0);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnEffectProc += AuraEffectProcFn(spell_oculus_evasive_maneuvers_AuraScript::HandleProc, EFFECT_2, SPELL_AURA_PROC_TRIGGER_SPELL);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_oculus_evasive_maneuvers_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 49840 - Shock Lance
|
||||
class spell_oculus_shock_lance : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_oculus_shock_lance() : SpellScriptLoader("spell_oculus_shock_lance") { }
|
||||
|
||||
class spell_oculus_shock_lance_SpellScript : public SpellScript
|
||||
{
|
||||
PrepareSpellScript(spell_oculus_shock_lance_SpellScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/)
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(SPELL_AMBER_SHOCK_CHARGE))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void CalcDamage()
|
||||
{
|
||||
int32 damage = GetHitDamage();
|
||||
if (Unit* target = GetHitUnit())
|
||||
if (Aura* aura = target->GetAura(SPELL_AMBER_SHOCK_CHARGE, GetCaster()->GetGUID())) // shock charges from same caster
|
||||
{
|
||||
damage += aura->GetStackAmount()*6525;
|
||||
aura->Remove();
|
||||
}
|
||||
|
||||
SetHitDamage(damage);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnHit += SpellHitFn(spell_oculus_shock_lance_SpellScript::CalcDamage);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
{
|
||||
return new spell_oculus_shock_lance_SpellScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 49592 - Temporal Rift
|
||||
class spell_oculus_temporal_rift : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_oculus_temporal_rift() : SpellScriptLoader("spell_oculus_temporal_rift") { }
|
||||
|
||||
class spell_oculus_temporal_rift_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_oculus_temporal_rift_AuraScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/)
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(SPELL_AMBER_SHOCK_CHARGE))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
|
||||
{
|
||||
PreventDefaultAction();
|
||||
int32 amount = aurEff->GetAmount() + eventInfo.GetDamageInfo()->GetDamage();
|
||||
|
||||
uint8 num = amount/15000;
|
||||
if (amount >= 15000)
|
||||
{
|
||||
if (Unit* caster = GetCaster())
|
||||
for (uint8 i =0; i < num; ++i )
|
||||
caster->CastSpell(GetTarget(), SPELL_AMBER_SHOCK_CHARGE, true);
|
||||
}
|
||||
|
||||
const_cast<AuraEffect*>(aurEff)->SetAmount(amount - 15000*num);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnEffectProc += AuraEffectProcFn(spell_oculus_temporal_rift_AuraScript::HandleProc, EFFECT_2, SPELL_AURA_DUMMY);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_oculus_temporal_rift_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 50341 - Touch the Nightmare
|
||||
class spell_oculus_touch_the_nightmare : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_oculus_touch_the_nightmare() : SpellScriptLoader("spell_oculus_touch_the_nightmare") { }
|
||||
|
||||
class spell_oculus_touch_the_nightmare_SpellScript : public SpellScript
|
||||
{
|
||||
PrepareSpellScript(spell_oculus_touch_the_nightmare_SpellScript);
|
||||
|
||||
void HandleDamageCalc(SpellEffIndex /*effIndex*/)
|
||||
{
|
||||
SetHitDamage(int32(GetCaster()->CountPctFromMaxHealth(30)));
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnEffectHitTarget += SpellEffectFn(spell_oculus_touch_the_nightmare_SpellScript::HandleDamageCalc, EFFECT_2, SPELL_EFFECT_SCHOOL_DAMAGE);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
{
|
||||
return new spell_oculus_touch_the_nightmare_SpellScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 50344 - Dream Funnel
|
||||
class spell_oculus_dream_funnel : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_oculus_dream_funnel() : SpellScriptLoader("spell_oculus_dream_funnel") { }
|
||||
|
||||
class spell_oculus_dream_funnel_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_oculus_dream_funnel_AuraScript);
|
||||
|
||||
void HandleEffectCalcAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& canBeRecalculated)
|
||||
{
|
||||
if (Unit* caster = GetCaster())
|
||||
amount = int32(caster->CountPctFromMaxHealth(5));
|
||||
|
||||
canBeRecalculated = false;
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_oculus_dream_funnel_AuraScript::HandleEffectCalcAmount, EFFECT_0, SPELL_AURA_PERIODIC_HEAL);
|
||||
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_oculus_dream_funnel_AuraScript::HandleEffectCalcAmount, EFFECT_2, SPELL_AURA_PERIODIC_DAMAGE);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_oculus_dream_funnel_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
class spell_oculus_call_ruby_emerald_amber_drake : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_oculus_call_ruby_emerald_amber_drake() : SpellScriptLoader("spell_oculus_call_ruby_emerald_amber_drake") { }
|
||||
|
||||
class spell_oculus_call_ruby_emerald_amber_drake_SpellScript : public SpellScript
|
||||
{
|
||||
PrepareSpellScript(spell_oculus_call_ruby_emerald_amber_drake_SpellScript);
|
||||
|
||||
void SetDest(SpellDestination& dest)
|
||||
{
|
||||
// Adjust effect summon position
|
||||
Position const offset = { 0.0f, 0.0f, 12.0f, 0.0f };
|
||||
dest.RelocateOffset(offset);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnDestinationTargetSelect += SpellDestinationTargetSelectFn(spell_oculus_call_ruby_emerald_amber_drake_SpellScript::SetDest, EFFECT_0, TARGET_DEST_CASTER_FRONT);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
{
|
||||
return new spell_oculus_call_ruby_emerald_amber_drake_SpellScript();
|
||||
}
|
||||
};
|
||||
|
||||
class spell_oculus_ride_ruby_emerald_amber_drake_que : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_oculus_ride_ruby_emerald_amber_drake_que() : SpellScriptLoader("spell_oculus_ride_ruby_emerald_amber_drake_que") { }
|
||||
|
||||
class spell_oculus_ride_ruby_emerald_amber_drake_que_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_oculus_ride_ruby_emerald_amber_drake_que_AuraScript);
|
||||
|
||||
void HandlePeriodic(AuraEffect const* aurEff)
|
||||
{
|
||||
// caster of the triggered spell is wrong for an unknown reason, handle it here correctly
|
||||
PreventDefaultAction();
|
||||
if (Unit* caster = GetCaster())
|
||||
GetTarget()->CastSpell(caster, GetSpellInfo()->Effects[aurEff->GetEffIndex()].TriggerSpell, true);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnEffectPeriodic += AuraEffectPeriodicFn(spell_oculus_ride_ruby_emerald_amber_drake_que_AuraScript::HandlePeriodic, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_oculus_ride_ruby_emerald_amber_drake_que_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
void AddSC_oculus()
|
||||
{
|
||||
new npc_oculus_drakegiver();
|
||||
new npc_oculus_drake();
|
||||
|
||||
new spell_oculus_stop_time();
|
||||
new spell_oculus_evasive_maneuvers();
|
||||
new spell_oculus_shock_lance();
|
||||
new spell_oculus_temporal_rift();
|
||||
new spell_oculus_touch_the_nightmare();
|
||||
new spell_oculus_dream_funnel();
|
||||
new spell_oculus_call_ruby_emerald_amber_drake();
|
||||
new spell_oculus_ride_ruby_emerald_amber_drake_que();
|
||||
}
|
||||
@@ -1,77 +0,0 @@
|
||||
/*
|
||||
REWRITTEN FROM SCRATCH BY PUSSYWIZARD, IT OWNS NOW!
|
||||
*/
|
||||
|
||||
#ifndef DEF_OCULUS_H
|
||||
#define DEF_OCULUS_H
|
||||
|
||||
enum Data
|
||||
{
|
||||
DATA_DRAKOS, // Drakos the Interrogator
|
||||
DATA_VAROS, // Varos Cloudstrider
|
||||
DATA_UROM, // Mage-Lord Urom
|
||||
DATA_EREGOS, // Ley-Guardian Eregos
|
||||
MAX_ENCOUNTER,
|
||||
DATA_CC_COUNT,
|
||||
DATA_AMBER_VOID,
|
||||
DATA_EMERALD_VOID,
|
||||
DATA_RUBY_VOID,
|
||||
DATA_DCD_1 = 100,
|
||||
DATA_DCD_2 = 101,
|
||||
DATA_DCD_3 = 102,
|
||||
};
|
||||
|
||||
enum NPCs
|
||||
{
|
||||
NPC_DRAKOS = 27654,
|
||||
NPC_VAROS = 27447,
|
||||
NPC_UROM = 27655,
|
||||
NPC_EREGOS = 27656,
|
||||
|
||||
NPC_VERDISA = 27657,
|
||||
NPC_BELGARISTRASZ = 27658,
|
||||
NPC_ETERNOS = 27659,
|
||||
|
||||
NPC_AMBER_DRAKE = 27755,
|
||||
NPC_EMERALD_DRAKE = 27692,
|
||||
NPC_RUBY_DRAKE = 27756,
|
||||
|
||||
NPC_CENTRIFUGE_CONSTRUCT = 27641,
|
||||
|
||||
NPC_IMAGE_OF_BELGARISTRASZ = 28012,
|
||||
};
|
||||
|
||||
enum Items
|
||||
{
|
||||
ITEM_EMERALD_ESSENCE = 37815,
|
||||
ITEM_AMBER_ESSENCE = 37859,
|
||||
ITEM_RUBY_ESSENCE = 37860,
|
||||
};
|
||||
|
||||
enum GOs
|
||||
{
|
||||
GO_DRAGON_CAGE = 189986,
|
||||
GO_DRAGON_CAGE_DOOR = 193995,
|
||||
GO_CACHE_OF_EREGOS = 191349,
|
||||
GO_CACHE_OF_EREGOS_HERO = 193603,
|
||||
GO_SPOTLIGHT = 191351,
|
||||
};
|
||||
|
||||
enum AchievData
|
||||
{
|
||||
ACHIEV_MAKE_IT_COUNT_TIMED_EVENT = 18153,
|
||||
CRITERIA_EXPERIENCED_AMBER = 7177,
|
||||
CRITERIA_EXPERIENCED_EMERALD = 7178,
|
||||
CRITERIA_EXPERIENCED_RUBY = 7179,
|
||||
CRITERIA_AMBER_VOID = 7325,
|
||||
CRITERIA_EMERALD_VOID = 7324,
|
||||
CRITERIA_RUBY_VOID = 7323,
|
||||
};
|
||||
|
||||
enum OculusWorldStates
|
||||
{
|
||||
WORLD_STATE_CENTRIFUGE_CONSTRUCT_SHOW = 3524,
|
||||
WORLD_STATE_CENTRIFUGE_CONSTRUCT_AMOUNT = 3486
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user