Added check for placed blocks in backfill

This commit is contained in:
Lucas Arden 2022-07-26 14:21:32 -07:00
parent d7fc916d20
commit d37a6a0b2d

View File

@ -56,12 +56,12 @@ public final class BackfillProcess extends BaritoneProcessHelper {
Baritone.settings().backfill.value = false; Baritone.settings().backfill.value = false;
return false; return false;
} }
amIBreakingABlockHMMMMMMM();
for (BlockPos pos : new ArrayList<>(blocksToReplace.keySet())) { for (BlockPos pos : new ArrayList<>(blocksToReplace.keySet())) {
if (ctx.world().getChunk(pos) instanceof EmptyChunk) { if (ctx.world().getChunk(pos) instanceof EmptyChunk || ctx.world().getBlockState(pos).getBlock() != Blocks.AIR) {
blocksToReplace.remove(pos); blocksToReplace.remove(pos);
} }
} }
amIBreakingABlockHMMMMMMM();
baritone.getInputOverrideHandler().clearAllKeys(); baritone.getInputOverrideHandler().clearAllKeys();
return !toFillIn().isEmpty(); return !toFillIn().isEmpty();