mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-16 18:40:28 +00:00
fix(Core/Movement): Water-bound creatures should not evade if their t… (#12112)
fix(Core/Movement): Water-bound creatures should not evade if their target is near the surface/jumping in the water. Fixed #10383
This commit is contained in:
@@ -3870,7 +3870,11 @@ bool Unit::isInAccessiblePlaceFor(Creature const* c) const
|
||||
return false;
|
||||
}
|
||||
|
||||
if (IsInWater())
|
||||
LiquidStatus liquidStatus = GetLiquidData().Status;
|
||||
bool isInWater = (liquidStatus & MAP_LIQUID_STATUS_SWIMMING) != 0;
|
||||
|
||||
// In water or jumping in water
|
||||
if (isInWater || (liquidStatus == LIQUID_MAP_ABOVE_WATER && (IsFalling() || (ToPlayer() && ToPlayer()->IsFalling()))))
|
||||
{
|
||||
return c->CanEnterWater();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user