Caused by incorrect order of operations when buying a train engine with refit and attaching free wagons.
(cherry picked from commit ee2d0745e9
)
This commit is contained in:

committed by
Jonathan G Rennison

parent
5c2f9dffe6
commit
98788e865f
@@ -264,11 +264,10 @@ void RoadVehUpdateCache(RoadVehicle *v, bool same_length)
|
||||
* @param tile tile of the depot where road vehicle is built.
|
||||
* @param flags type of operation.
|
||||
* @param e the engine to build.
|
||||
* @param data unused.
|
||||
* @param[out] ret the vehicle that has been built.
|
||||
* @return the cost of this operation or an error.
|
||||
*/
|
||||
CommandCost CmdBuildRoadVehicle(TileIndex tile, DoCommandFlag flags, const Engine *e, uint16 data, Vehicle **ret)
|
||||
CommandCost CmdBuildRoadVehicle(TileIndex tile, DoCommandFlag flags, const Engine *e, Vehicle **ret)
|
||||
{
|
||||
/* Check that the vehicle can drive on the road in question */
|
||||
RoadType rt = e->u.road.roadtype;
|
||||
|
Reference in New Issue
Block a user