thebes uwu
This commit is contained in:
parent
80c8294f5f
commit
e42c19bfec
@ -30,8 +30,8 @@ import java.awt.*;
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.ParameterizedType;
|
||||
import java.lang.reflect.Type;
|
||||
import java.util.*;
|
||||
import java.util.List;
|
||||
import java.util.*;
|
||||
import java.util.function.Consumer;
|
||||
|
||||
/**
|
||||
@ -193,6 +193,15 @@ public final class Settings {
|
||||
|
||||
)));
|
||||
|
||||
/**
|
||||
* A list of blocks to become air
|
||||
* <p>
|
||||
* If a schematic asks for a block on this list, only air will be accepted at that location (and nothing on buildIgnoreBlocks)
|
||||
*/
|
||||
public final Setting<List<Block>> okIfAir = new Setting<>(new ArrayList<>(Arrays.asList(
|
||||
|
||||
)));
|
||||
|
||||
/**
|
||||
* If this is true, the builder will treat all non-air blocks as correct. It will only place new blocks.
|
||||
*/
|
||||
|
@ -206,6 +206,7 @@ public final class BuilderProcess extends BaritoneProcessHelper implements IBuil
|
||||
continue; // irrelevant
|
||||
}
|
||||
IBlockState curr = bcc.bsi.get0(x, y, z);
|
||||
Blocks.ICE;
|
||||
if (curr.getBlock() != Blocks.AIR && !(curr.getBlock() instanceof BlockLiquid) && !valid(curr, desired, false)) {
|
||||
BetterBlockPos pos = new BetterBlockPos(x, y, z);
|
||||
Optional<Rotation> rot = RotationUtils.reachable(ctx.player(), pos, ctx.playerController().getBlockReachDistance());
|
||||
@ -773,10 +774,12 @@ public final class BuilderProcess extends BaritoneProcessHelper implements IBuil
|
||||
if (desired == null) {
|
||||
return true;
|
||||
}
|
||||
// TODO more complicated comparison logic I guess
|
||||
if (current.getBlock() instanceof BlockLiquid && Baritone.settings().okIfWater.value) {
|
||||
return true;
|
||||
}
|
||||
if (current.getBlock() instanceof BlockAir && Baritone.settings().okIfAir.value.contains(desired.getBlock())) {
|
||||
return true;
|
||||
}
|
||||
if (desired.getBlock() instanceof BlockAir && Baritone.settings().buildIgnoreBlocks.value.contains(current.getBlock())) {
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user