fix(Core/Movement): creatures should not cast while moving (#9141)
- Closes #8843
This commit is contained in:
parent
006ee3b7e2
commit
70fbaefa8e
10 changed files with 53 additions and 52 deletions
|
|
@ -121,8 +121,11 @@ void ConfusedMovementGenerator<T>::DoReset(T* unit)
|
|||
template<class T>
|
||||
bool ConfusedMovementGenerator<T>::DoUpdate(T* unit, uint32 diff)
|
||||
{
|
||||
if (unit->HasUnitState(UNIT_STATE_ROOT | UNIT_STATE_STUNNED | UNIT_STATE_DISTRACTED))
|
||||
if (unit->HasUnitState(UNIT_STATE_NOT_MOVE) || unit->IsMovementPreventedByCasting())
|
||||
{
|
||||
unit->StopMoving();
|
||||
return true;
|
||||
}
|
||||
|
||||
if (i_nextMoveTime.Passed())
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue