src/town_cmd.cpp
changeset 8957 ed06a4be28b9
parent 8947 3b7bb9f2770c
child 8981 005e2c86844c
equal deleted inserted replaced
8956:0830ab903057 8957:ed06a4be28b9
  1187 
  1187 
  1188 		if (IsTileType(tile, MP_ROAD)) {
  1188 		if (IsTileType(tile, MP_ROAD)) {
  1189 			/* Don't allow building over roads of other cities */
  1189 			/* Don't allow building over roads of other cities */
  1190 			if (IsTileOwner(tile, OWNER_TOWN) && GetTownByTile(tile) != t) {
  1190 			if (IsTileOwner(tile, OWNER_TOWN) && GetTownByTile(tile) != t) {
  1191 				_grow_town_result = GROWTH_SUCCEED;
  1191 				_grow_town_result = GROWTH_SUCCEED;
  1192 			} else if (_game_mode == GM_EDITOR) {
  1192 			} else if (IsTileOwner(tile, OWNER_NONE) && _game_mode == GM_EDITOR) {
  1193 				/* If we are in the SE, and this road-piece has no town owner yet, it just found an
  1193 				/* If we are in the SE, and this road-piece has no town owner yet, it just found an
  1194 				 * owner :) (happy happy happy road now) */
  1194 				 * owner :) (happy happy happy road now) */
  1195 				SetTileOwner(tile, OWNER_TOWN);
  1195 				SetTileOwner(tile, OWNER_TOWN);
  1196 				SetTownIndex(tile, t->index);
  1196 				SetTownIndex(tile, t->index);
  1197 			}
  1197 			}