(svn r2180) -Fix: Deceleration code now only takes into account rail station tiles for computing the remaining distance

This commit is contained in:
celestar 2005-04-11 14:59:06 +00:00
parent 6409e6efaf
commit a714444a8e

View File

@ -154,7 +154,7 @@ static int GetTrainAcceleration(Vehicle *v, bool mode)
do {
station_length++;
tile = TILE_ADD(tile, TileOffsByDir(v->direction / 2));
} while (IsTileType(tile, MP_STATION));
} while (IsTrainStationTile(tile) && (_map5[tile] & 1) == (_map5[v->tile] & 1));
delta_v = v->cur_speed / (station_length + 1);
if (v->max_speed > (v->cur_speed - delta_v))