mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-19 08:55:32 +01:00
*Grobbulus - fix Poison Cloud, by Cass
--HG-- branch : trunk
This commit is contained in:
@@ -769,6 +769,7 @@ UPDATE `creature_template` SET `ScriptName`='mob_gothik_minion' where `entry` IN
|
||||
UPDATE `creature_template` SET `ScriptName`='boss_four_horsemen' WHERE `entry` IN (16063,16064,16065,30549);
|
||||
UPDATE `creature_template` SET `ScriptName`='boss_patchwerk' WHERE `entry`=16028;
|
||||
UPDATE `creature_template` SET `ScriptName`='boss_grobbulus' WHERE `entry`=15931;
|
||||
UPDATE `creature_template` SET `ScriptName`='npc_grobbulus_poison_cloud' WHERE `entry`=16363;
|
||||
UPDATE `creature_template` SET `ScriptName`='boss_gluth' WHERE `entry`=15932;
|
||||
UPDATE `creature_template` SET `ScriptName`='boss_thaddius' WHERE `entry`=15928;
|
||||
UPDATE `creature_template` SET `ScriptName`='boss_stalagg' WHERE `entry`=15929;
|
||||
|
||||
2
sql/updates/5872_world_scripts.sql
Normal file
2
sql/updates/5872_world_scripts.sql
Normal file
@@ -0,0 +1,2 @@
|
||||
|
||||
UPDATE `creature_template` SET `ScriptName`='npc_grobbulus_poison_cloud' WHERE `entry`=16363;
|
||||
@@ -23,6 +23,7 @@
|
||||
#define SPELL_MUTATING_INJECTION 28169
|
||||
#define SPELL_SLIME_SPRAY HEROIC(28157,54364)
|
||||
#define SPELL_BERSERK 26662
|
||||
#define SPELL_POISON_CLOUD_ADD 59116
|
||||
|
||||
#define EVENT_BERSERK 1
|
||||
#define EVENT_CLOUD 2
|
||||
@@ -33,7 +34,10 @@
|
||||
|
||||
struct TRINITY_DLL_DECL boss_grobbulusAI : public BossAI
|
||||
{
|
||||
boss_grobbulusAI(Creature *c) : BossAI(c, BOSS_GROBBULUS) {}
|
||||
boss_grobbulusAI(Creature *c) : BossAI(c, BOSS_GROBBULUS)
|
||||
{
|
||||
me->ApplySpellImmune(0, IMMUNITY_ID, SPELL_POISON_CLOUD_ADD, true);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit *who)
|
||||
{
|
||||
@@ -88,11 +92,41 @@ struct TRINITY_DLL_DECL boss_grobbulusAI : public BossAI
|
||||
}
|
||||
};
|
||||
|
||||
struct TRINITY_DLL_DECL npc_grobbulus_poison_cloudAI : public Scripted_NoMovementAI
|
||||
{
|
||||
npc_grobbulus_poison_cloudAI(Creature* pCreature) : Scripted_NoMovementAI(pCreature)
|
||||
{
|
||||
Reset();
|
||||
}
|
||||
|
||||
uint32 Cloud_Timer;
|
||||
|
||||
void Reset()
|
||||
{
|
||||
Cloud_Timer = 1000;
|
||||
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
{
|
||||
if (Cloud_Timer < diff)
|
||||
{
|
||||
DoCast(m_creature, SPELL_POISON_CLOUD_ADD);
|
||||
Cloud_Timer = 10000;
|
||||
} else Cloud_Timer -= diff;
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI_boss_grobbulus(Creature* pCreature)
|
||||
{
|
||||
return new boss_grobbulusAI (pCreature);
|
||||
}
|
||||
|
||||
CreatureAI* GetAI_npc_grobbulus_poison_cloud(Creature* pCreature)
|
||||
{
|
||||
return new npc_grobbulus_poison_cloudAI(pCreature);
|
||||
}
|
||||
|
||||
void AddSC_boss_grobbulus()
|
||||
{
|
||||
Script *newscript;
|
||||
@@ -100,4 +134,9 @@ void AddSC_boss_grobbulus()
|
||||
newscript->Name="boss_grobbulus";
|
||||
newscript->GetAI = &GetAI_boss_grobbulus;
|
||||
newscript->RegisterSelf();
|
||||
|
||||
newscript = new Script;
|
||||
newscript->Name = "npc_grobbulus_poison_cloud";
|
||||
newscript->GetAI = &GetAI_npc_grobbulus_poison_cloud;
|
||||
newscript->RegisterSelf();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user