Skip to content

Commit

Permalink
Core/Creature: Prevent friendly vehicles from trying to attack their …
Browse files Browse the repository at this point in the history
…rider after dismounting.
  • Loading branch information
Treeston committed Mar 1, 2016
1 parent ecd9dec commit 89e2afb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/server/game/Entities/Creature/Creature.cpp
Expand Up @@ -578,7 +578,8 @@ void Creature::Update(uint32 diff)
IsAIEnabled = true;
if (!IsInEvadeMode() && LastCharmerGUID)
if (Unit* charmer = ObjectAccessor::GetUnit(*this, LastCharmerGUID))
i_AI->AttackStart(charmer);
if (CanStartAttack(charmer, true))
i_AI->AttackStart(charmer);

LastCharmerGUID.Clear();
}
Expand Down

0 comments on commit 89e2afb

Please sign in to comment.