src/station.cpp
branchnoai
changeset 10776 07203fc29812
parent 10715 6bdf79ffb022
equal deleted inserted replaced
10774:2c882f0468f2 10776:07203fc29812
   283 		Rect new_rect = {min(x, left), min(y, top), max(x, right), max(y, bottom)};
   283 		Rect new_rect = {min(x, left), min(y, top), max(x, right), max(y, bottom)};
   284 
   284 
   285 		/* check new rect dimensions against preset max */
   285 		/* check new rect dimensions against preset max */
   286 		int w = new_rect.right - new_rect.left + 1;
   286 		int w = new_rect.right - new_rect.left + 1;
   287 		int h = new_rect.bottom - new_rect.top + 1;
   287 		int h = new_rect.bottom - new_rect.top + 1;
   288 		if (mode != ADD_FORCE && (w > _settings.station.station_spread || h > _settings.station.station_spread)) {
   288 		if (mode != ADD_FORCE && (w > _settings_game.station.station_spread || h > _settings_game.station.station_spread)) {
   289 			assert(mode != ADD_TRY);
   289 			assert(mode != ADD_TRY);
   290 			_error_message = STR_306C_STATION_TOO_SPREAD_OUT;
   290 			_error_message = STR_306C_STATION_TOO_SPREAD_OUT;
   291 			return false;
   291 			return false;
   292 		}
   292 		}
   293 
   293