add setting to just skip layers that the builder fails to construct
This commit is contained in:
parent
320a5d64a3
commit
c491d67925
@ -814,6 +814,11 @@ public final class Settings {
|
|||||||
*/
|
*/
|
||||||
public final Setting<Integer> startAtLayer = new Setting<>(0);
|
public final Setting<Integer> startAtLayer = new Setting<>(0);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* If a layer is unable to be constructed, just skip it.
|
||||||
|
*/
|
||||||
|
public final Setting<Boolean> skipFailedLayers = new Setting<>(false);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* How far to move before repeating the build. 0 to disable repeating on a certain axis, 0,0,0 to disable entirely
|
* How far to move before repeating the build. 0 to disable repeating on a certain axis, 0,0,0 to disable entirely
|
||||||
*/
|
*/
|
||||||
|
@ -484,6 +484,11 @@ public final class BuilderProcess extends BaritoneProcessHelper implements IBuil
|
|||||||
if (goal == null) {
|
if (goal == null) {
|
||||||
goal = assemble(bcc, approxPlaceable); // we're far away, so assume that we have our whole inventory to recalculate placeable properly
|
goal = assemble(bcc, approxPlaceable); // we're far away, so assume that we have our whole inventory to recalculate placeable properly
|
||||||
if (goal == null) {
|
if (goal == null) {
|
||||||
|
if (Baritone.settings().skipFailedLayers.value && Baritone.settings().buildInLayers.value && layer < realSchematic.heightY()) {
|
||||||
|
logDirect("Skipping layer that I cannot construct! Layer #" + layer);
|
||||||
|
layer++;
|
||||||
|
return onTick(calcFailed, isSafeToCancel);
|
||||||
|
}
|
||||||
logDirect("Unable to do it. Pausing. resume to resume, cancel to cancel");
|
logDirect("Unable to do it. Pausing. resume to resume, cancel to cancel");
|
||||||
paused = true;
|
paused = true;
|
||||||
return new PathingCommand(null, PathingCommandType.REQUEST_PAUSE);
|
return new PathingCommand(null, PathingCommandType.REQUEST_PAUSE);
|
||||||
|
Loading…
Reference in New Issue
Block a user