Add setting for whether to allow converting town road to non-house types
See: 51e22617
This commit is contained in:
@@ -3117,8 +3117,9 @@ CommandCost CmdConvertRoad(TileIndex tile, DoCommandFlag flags, uint32 p1, uint3
|
||||
}
|
||||
}
|
||||
|
||||
/* Disallow converting town roads to types which do not allow houses */
|
||||
if (rtt == RTT_ROAD && owner == OWNER_TOWN && HasBit(GetRoadTypeInfo(to_type)->flags, ROTF_NO_HOUSES)) {
|
||||
/* Disallow converting town roads to types which do not allow houses, unless this is allowed */
|
||||
if (rtt == RTT_ROAD && owner == OWNER_TOWN && HasBit(GetRoadTypeInfo(to_type)->flags, ROTF_NO_HOUSES)
|
||||
&& !_settings_game.construction.convert_town_road_no_houses) {
|
||||
error.MakeError(STR_ERROR_OWNED_BY);
|
||||
GetNameOfOwner(OWNER_TOWN, tile);
|
||||
continue;
|
||||
|
Reference in New Issue
Block a user