diff options
Diffstat (limited to 'src/roadveh_cmd.cpp')
-rw-r--r-- | src/roadveh_cmd.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/roadveh_cmd.cpp b/src/roadveh_cmd.cpp index 0c0157ab1..6a8225050 100644 --- a/src/roadveh_cmd.cpp +++ b/src/roadveh_cmd.cpp @@ -416,7 +416,7 @@ void RoadVehicle::UpdateDeltaXY(Direction direction) */ inline int RoadVehicle::GetCurrentMaxSpeed() const { - if (_settings_game.vehicle.roadveh_acceleration_model == AM_ORIGINAL) return this->vcache.cached_max_speed; + if (_settings_game.vehicle.roadveh_acceleration_model == AM_ORIGINAL) return min(this->vcache.cached_max_speed, this->current_order.max_speed * 2); int max_speed = this->vcache.cached_max_speed; @@ -430,7 +430,7 @@ inline int RoadVehicle::GetCurrentMaxSpeed() const } } - return max_speed; + return min(max_speed, this->current_order.max_speed * 2); } /** |