diff options
| author | megamage <none@none> | 2009-05-27 23:26:08 -0500 |
|---|---|---|
| committer | megamage <none@none> | 2009-05-27 23:26:08 -0500 |
| commit | 773f9d072c8cd6bc8859f49c37161070a2bb29c9 (patch) | |
| tree | 104abf77e313d838bbb88701313ea7e89092c923 /src/bindings/scripts/include | |
| parent | c61ef6c73c1e69162acc97eb8539af284cf5c937 (diff) | |
*Set boss active=false after they arrive home. This fix the bug that boss is stuck at some far away grid and there spawns another boss.
--HG--
branch : trunk
Diffstat (limited to 'src/bindings/scripts/include')
| -rw-r--r-- | src/bindings/scripts/include/sc_creature.cpp | 1 | ||||
| -rw-r--r-- | src/bindings/scripts/include/sc_creature.h | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/src/bindings/scripts/include/sc_creature.cpp b/src/bindings/scripts/include/sc_creature.cpp index aa2a3fbf324..347330c2006 100644 --- a/src/bindings/scripts/include/sc_creature.cpp +++ b/src/bindings/scripts/include/sc_creature.cpp @@ -621,7 +621,6 @@ BossAI::BossAI(Creature *c, uint32 id) : ScriptedAI(c) void BossAI::_Reset() { - me->setActive(false); events.Reset(); summons.DespawnAll(); if(instance) diff --git a/src/bindings/scripts/include/sc_creature.h b/src/bindings/scripts/include/sc_creature.h index 6208d10c39e..88801227493 100644 --- a/src/bindings/scripts/include/sc_creature.h +++ b/src/bindings/scripts/include/sc_creature.h @@ -219,11 +219,13 @@ struct TRINITY_DLL_DECL BossAI : public ScriptedAI void Reset() { _Reset(); } void EnterCombat(Unit *who) { _EnterCombat(); } void JustDied(Unit *killer) { _JustDied(); } + void JustReachedHome() { me->setActive(false); } protected: void _Reset(); void _EnterCombat(); void _JustDied(); + void _JustReachedHome() { me->setActive(false); } bool CheckInRoom() { |
