From b22fb43ceafe9ec5643de1e88ec892ba08bd56d0 Mon Sep 17 00:00:00 2001 From: SamuXarick <43006711+SamuXarick@users.noreply.github.com> Date: Fri, 23 Feb 2024 13:08:16 +0000 Subject: [PATCH] Fix #10490: Allow ships to exit depots if another is not moving at the exit point (#12161) --- src/ship_cmd.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ship_cmd.cpp b/src/ship_cmd.cpp index dc57b19125..a2d1210c29 100644 --- a/src/ship_cmd.cpp +++ b/src/ship_cmd.cpp @@ -364,11 +364,11 @@ void Ship::UpdateDeltaXY() } /** - * Test-procedure for HasVehicleOnPos to check for any ships which are visible and not stopped by the player. + * Test-procedure for HasVehicleOnPos to check for any ships which are moving. */ static Vehicle *EnsureNoMovingShipProc(Vehicle *v, void *) { - return v->type == VEH_SHIP && (v->vehstatus & (VS_HIDDEN | VS_STOPPED)) == 0 ? v : nullptr; + return v->type == VEH_SHIP && v->cur_speed != 0 ? v : nullptr; } static bool CheckReverseShip(const Ship *v, Trackdir *trackdir = nullptr) -- 2.11.4.GIT