aboutsummaryrefslogtreecommitdiff
path: root/src/game/NullCreatureAI.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/NullCreatureAI.cpp')
-rw-r--r--src/game/NullCreatureAI.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/game/NullCreatureAI.cpp b/src/game/NullCreatureAI.cpp
index be59ed6e40d..5547ad8f059 100644
--- a/src/game/NullCreatureAI.cpp
+++ b/src/game/NullCreatureAI.cpp
@@ -20,6 +20,7 @@
#include "NullCreatureAI.h"
#include "Creature.h"
+#include "TemporarySummon.h"
void PassiveAI::UpdateAI(const uint32)
{
@@ -68,3 +69,13 @@ void CritterAI::EnterEvadeMode()
me->SetControlled(false, UNIT_STAT_FLEEING);
CreatureAI::EnterEvadeMode();
}
+
+void TriggerAI::UpdateAI(const uint32 diff)
+{
+ if(!casted)
+ {
+ casted = true;
+ if(me->m_spells[0] && me->isSummon())
+ me->CastSpell(me, me->m_spells[0], false, 0, 0, ((TempSummon*)me)->GetSummonerGUID());
+ }
+}