(svn r3155) -Feature: [autoreplace] autoreplace can now remove cars from too long trains
-Trains will now remember the length of stations it visits and sell cars
when being autoreplaced if they became too long
-If it needs to remove cars, then it starts from the front and sells
all it can find until the train is short enough
-This only works for trains, that knows the station length of the route
so a full uninterrupted run is needed
-a train needs 1-2 runs to detect if the shortest station is expanded
-This feature can be turned on and off in the train replace window
and each company can have it's own setting
-NOTE: minor savegame version bump
This commit is contained in:
@@ -320,6 +320,11 @@ static inline bool IsBuoyTile(TileIndex tile)
|
||||
return IsTileType(tile, MP_STATION) && _m[tile].m5 == 0x52;
|
||||
}
|
||||
|
||||
static inline bool TileBelongsToRailStation(const Station *st, TileIndex tile)
|
||||
{
|
||||
return IsTileType(tile, MP_STATION) && _m[tile].m2 == st->index && _m[tile].m5 < 8;
|
||||
}
|
||||
|
||||
/* Get's the direction the station exit points towards. Ie, returns 0 for a
|
||||
* station with the exit NE. */
|
||||
static inline byte GetRoadStationDir(TileIndex tile)
|
||||
|
||||
Reference in New Issue
Block a user