*Make some boss scripts safer. But I still strongly recommend that you do not spawn instance bosses outside the instance. They may make server crash like hell.

--HG--
branch : trunk
This commit is contained in:
megamage
2009-05-16 22:45:13 -05:00
parent c583767ad6
commit 698b43f088
+6 -3
View File
@@ -654,20 +654,23 @@ void BossAI::_Reset()
{
events.Reset();
summons.DespawnAll();
instance->SetBossState(bossId, NOT_STARTED);
if(instance)
instance->SetBossState(bossId, NOT_STARTED);
}
void BossAI::_JustDied()
{
events.Reset();
summons.DespawnAll();
instance->SetBossState(bossId, DONE);
if(instance)
instance->SetBossState(bossId, DONE);
}
void BossAI::_EnterCombat()
{
DoZoneInCombat();
instance->SetBossState(bossId, IN_PROGRESS);
if(instance)
instance->SetBossState(bossId, IN_PROGRESS);
}
void BossAI::JustSummoned(Creature *summon)