(svn r26375) -Fix [FS#5929]: Station sizes > 8 were always allowed. (adf88)

This commit is contained in:
frosch
2014-02-24 19:57:18 +00:00
parent 1f056ce552
commit 504bd2a913
2 changed files with 12 additions and 8 deletions

View File

@@ -1213,7 +1213,7 @@ CommandCost CmdBuildRailStation(TileIndex tile_org, DoCommandFlag flags, uint32
/* Perform NewStation checks */
/* Check if the station size is permitted */
if (HasBit(statspec->disallowed_platforms, numtracks - 1) || HasBit(statspec->disallowed_lengths, plat_len - 1)) {
if (HasBit(statspec->disallowed_platforms, min(numtracks - 1, 7)) || HasBit(statspec->disallowed_lengths, min(plat_len - 1, 7))) {
return CMD_ERROR;
}