Core/Misc: Small code optimisations
This commit is contained in:
1 parent
9d7d68395c
commit
2c2fe7d464
2 files changed
+49
-23
No files matched your search
@@ -15299,26 +15299,26 @@ void Unit::SetControlled(bool apply, UnitState state)
|
||||
case UNIT_STATE_STUNNED:
|
||||
if (HasAuraType(SPELL_AURA_MOD_STUN))
|
||||
return;
|
||||
else
|
||||
SetStunned(false);
|
||||
|
||||
SetStunned(false);
|
||||
break;
|
||||
case UNIT_STATE_ROOT:
|
||||
if (HasAuraType(SPELL_AURA_MOD_ROOT) || GetVehicle())
|
||||
return;
|
||||
else
|
||||
SetRooted(false);
|
||||
|
||||
SetRooted(false);
|
||||
break;
|
||||
case UNIT_STATE_CONFUSED:
|
||||
if (HasAuraType(SPELL_AURA_MOD_CONFUSE))
|
||||
return;
|
||||
else
|
||||
SetConfused(false);
|
||||
|
||||
SetConfused(false);
|
||||
break;
|
||||
case UNIT_STATE_FLEEING:
|
||||
if (HasAuraType(SPELL_AURA_MOD_FEAR))
|
||||
return;
|
||||
else
|
||||
SetFeared(false);
|
||||
|
||||
SetFeared(false);
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
|
||||
Reference in new issue
Block a user