| 469 | } |
| 470 | |
| 471 | public static boolean isNextToAir(CalculationContext ctx, BlockPos pos) { |
| 472 | int radius = Baritone.settings().allowOnlyExposedOresDistance.value; |
| 473 | for (int dx = -radius; dx <= radius; dx++) { |
| 474 | for (int dy = -radius; dy <= radius; dy++) { |
| 475 | for (int dz = -radius; dz <= radius; dz++) { |
| 476 | if (Math.abs(dx) + Math.abs(dy) + Math.abs(dz) <= radius |
| 477 | && MovementHelper.isTransparent(ctx.getBlock(pos.getX() + dx, pos.getY() + dy, pos.getZ() + dz))) { |
| 478 | return true; |
| 479 | } |
| 480 | } |
| 481 | } |
| 482 | } |
| 483 | return false; |
| 484 | } |
| 485 | |
| 486 | |
| 487 | public static boolean plausibleToBreak(CalculationContext ctx, BlockPos pos) { |