Instance/Naxxramas: Loatheb no longer instantly murders you. Five spam casts of Doom tend to do that to raids.

This commit is contained in:
treeston
2016-09-20 14:13:31 +02:00
parent ab2acb2c0c
commit 59527521e6

View File

@@ -61,22 +61,14 @@ class boss_loatheb : public CreatureScript
struct boss_loathebAI : public BossAI
{
boss_loathebAI(Creature* creature) : BossAI(creature, BOSS_LOATHEB)
{
Initialize();
}
void Initialize()
{
_doomCounter = 0;
_sporeLoserData = true;
}
boss_loathebAI(Creature* creature) : BossAI(creature, BOSS_LOATHEB), _doomCounter(0), _sporeLoser(true) { }
void Reset() override
{
_Reset();
instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_FUNGAL_CREEP);
Initialize();
_doomCounter = 0;
_sporeLoser = true;
}
void EnterCombat(Unit* /*who*/) override
@@ -90,13 +82,13 @@ class boss_loatheb : public CreatureScript
void SummonedCreatureDies(Creature* summon, Unit* /*killer*/) override
{
_sporeLoserData = false;
summon->CastSpell(summon,SPELL_FUNGAL_CREEP,true);
_sporeLoser = false;
summon->CastSpell(summon, SPELL_FUNGAL_CREEP, true);
}
uint32 GetData(uint32 id) const override
{
return (_sporeLoserData && id == DATA_ACHIEVEMENT_SPORE_LOSER) ? 1u : 0u;
return (_sporeLoser && id == DATA_ACHIEVEMENT_SPORE_LOSER) ? 1u : 0u;
}
void UpdateAI(uint32 diff) override
@@ -122,12 +114,12 @@ class boss_loatheb : public CreatureScript
events.Repeat(Seconds(30));
break;
case EVENT_INEVITABLE_DOOM:
_doomCounter++;
++_doomCounter;
DoCastAOE(SPELL_INEVITABLE_DOOM);
if (_doomCounter > 6)
events.Repeat((_doomCounter & 1) ? Seconds(14) : Seconds(17));
else
events.Repeat(30);
events.Repeat(Seconds(30));
break;
case EVENT_SPORE:
DoCast(me, SPELL_SUMMON_SPORE, false);
@@ -148,7 +140,7 @@ class boss_loatheb : public CreatureScript
}
private:
bool _sporeLoserData;
bool _sporeLoser;
uint8 _doomCounter;
};