# HG changeset patch # User KUDr # Date 1156880791 0 # Node ID 562232eef864ff3072acaf88278b46fb306ba829 # Parent 9c9c7f962482418b162e53caf0ecc32cfa04e41f (svn r6223) -Fix: RVs with empty order list were able to enter the depot or road stop from the back. I introduced this bug when I "improved" GetTileTrackStatus(). (thanks glx for the report and fix). diff -r 9c9c7f962482 -r 562232eef864 roadveh_cmd.c --- a/roadveh_cmd.c Tue Aug 29 19:26:13 2006 +0000 +++ b/roadveh_cmd.c Tue Aug 29 19:46:31 2006 +0000 @@ -1035,13 +1035,13 @@ } if (IsTileType(tile, MP_STREET)) { - if (GetRoadTileType(tile) == ROAD_TILE_DEPOT && !IsTileOwner(tile, v->owner)) { - /* Road depot owned by another player */ + if (GetRoadTileType(tile) == ROAD_TILE_DEPOT && (!IsTileOwner(tile, v->owner) || GetRoadDepotDirection(tile) == enterdir)) { + /* Road depot owned by another player or with the wrong orientation */ bitmask = 0; } } else if (IsTileType(tile, MP_STATION) && IsRoadStopTile(tile)) { - if (!IsTileOwner(tile, v->owner)) { - // different station owner + if (!IsTileOwner(tile, v->owner) || GetRoadStopDir(tile) == enterdir) { + /* different station owner or wrong orientation */ bitmask = 0; } else { /* Our station */