aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/game/CreatureAI.cpp4
-rw-r--r--src/game/GameObject.cpp2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/game/CreatureAI.cpp b/src/game/CreatureAI.cpp
index 5fd35150b52..5cde80aaccb 100644
--- a/src/game/CreatureAI.cpp
+++ b/src/game/CreatureAI.cpp
@@ -86,14 +86,14 @@ void CreatureAI::DoZoneInCombat(Creature* creature)
if(!creature->getVictim())
{
if(Unit *target = creature->SelectNearestTarget())
- AttackStart(target);
+ creature->AI()->AttackStart(target);
else if(creature->isSummon())
{
if(Unit *summoner = ((TempSummon*)creature)->GetSummoner())
{
if(summoner->getVictim()
&& (creature->IsFriendlyTo(summoner) || creature->IsHostileTo(summoner->getVictim())))
- AttackStart(summoner->getVictim());
+ creature->AI()->AttackStart(summoner->getVictim());
}
}
}
diff --git a/src/game/GameObject.cpp b/src/game/GameObject.cpp
index 1a2ed5fb6db..540ea1e0dd7 100644
--- a/src/game/GameObject.cpp
+++ b/src/game/GameObject.cpp
@@ -174,7 +174,7 @@ bool GameObject::Create(uint32 guidlow, uint32 name_id, Map *map, uint32 phaseMa
//Normally non-players do not teleport to other maps.
if(map->IsDungeon() && ((InstanceMap*)map)->GetInstanceData())
{
- ((InstanceMap*)map)->GetInstanceData()->OnObjectCreate(this);
+ ((InstanceMap*)map)->GetInstanceData()->OnObjectCreate(this, true);
}
return true;