road_cmd.c
changeset 3637 74ecd9adcbb4
parent 3636 a36cc46e754d
child 3645 7f950533d510
equal deleted inserted replaced
3636:a36cc46e754d 3637:74ecd9adcbb4
   384 			if (CmdFailed(ret)) return ret;
   384 			if (CmdFailed(ret)) return ret;
   385 			cost += ret;
   385 			cost += ret;
   386 	}
   386 	}
   387 
   387 
   388 	ret = CheckRoadSlope(tileh, &pieces, existing);
   388 	ret = CheckRoadSlope(tileh, &pieces, existing);
   389 	if (CmdFailed(ret)) return_cmd_error(STR_1800_LAND_SLOPED_IN_WRONG_DIRECTION);
   389 	if (CmdFailed(ret)) return_cmd_error(STR_1000_LAND_SLOPED_IN_WRONG_DIRECTION);
   390 	if (ret != 0 && (!_patches.build_on_slopes || _is_old_ai_player)) {
   390 	if (ret != 0 && (!_patches.build_on_slopes || _is_old_ai_player)) {
   391 		return CMD_ERROR;
   391 		return CMD_ERROR;
   392 	}
   392 	}
   393 	cost += ret;
   393 	cost += ret;
   394 
   394