Class MineProcess
java.lang.Object
com.zenith.feature.pathfinder.process.BaritoneProcessHelper
com.zenith.feature.pathfinder.process.MineProcess
- All Implemented Interfaces:
IBaritoneProcess
-
Field Summary
Fields inherited from class com.zenith.feature.pathfinder.process.BaritoneProcessHelper
baritone, ctxFields inherited from interface com.zenith.feature.pathfinder.process.IBaritoneProcess
DEFAULT_PRIORITY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcancel()Cancels the current mining taskbooleanisActive()Would this process like to be in control?mine(int quantity, BlockOptionalMetaLookup filter) Begin to search for and mine the specified blocks.mine(BlockOptionalMetaLookup filter) Begin to search for and mine the specified blocks.Begin to search for and mine the specified blocks.mineByName(int quantity, String... blocks) mineByName(String... blocks) Begin to search for and mine the specified blocks.voidCalled ifIBaritoneProcess.isActive()returnedtrue, but another non-temporary process has control.onTick(boolean calcFailed, boolean isSafeToCancel, Goal currentGoal, PathingCommand prevCommand) Called when this process is in control of pathing; Returns what Baritone should do.static booleanplausibleToBreak(CalculationContext ctx, BlockPos pos) searchWorld(CalculationContext ctx, BlockOptionalMetaLookup filter, int max, List<BlockPos> alreadyKnown, List<BlockPos> blacklist, List<BlockPos> dropped) Methods inherited from class com.zenith.feature.pathfinder.process.BaritoneProcessHelper
isTemporary, stopMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.zenith.feature.pathfinder.process.IBaritoneProcess
displayName, isTemporary, priority, stop
-
Constructor Details
-
MineProcess
-
-
Method Details
-
isActive
public boolean isActive()Description copied from interface:IBaritoneProcessWould this process like to be in control?- Specified by:
isActivein interfaceIBaritoneProcess- Returns:
- Whether or not this process would like to be in contorl.
-
onTick
public PathingCommand onTick(boolean calcFailed, boolean isSafeToCancel, Goal currentGoal, PathingCommand prevCommand) Description copied from interface:IBaritoneProcessCalled when this process is in control of pathing; Returns what Baritone should do.- Specified by:
onTickin interfaceIBaritoneProcess- Parameters:
calcFailed-trueif this specific process was in control last tick, and there was aPathEvent.CALC_FAILEDevent last tickisSafeToCancel-trueif aPathingCommandType.REQUEST_PAUSEwould happen this tick, andPathingBehaviorwouldn't actually tick.falseif the PathExecutor reported pausing would be unsafe at the end of the last tick. Effectively "could request cancel or pause and have it happen right away"currentGoal-prevCommand-- Returns:
- What the
PathingBehaviorshould do
-
onLostControl
public void onLostControl()Description copied from interface:IBaritoneProcessCalled ifIBaritoneProcess.isActive()returnedtrue, but another non-temporary process has control. Effectively the same as cancel. You want control but you don't get it.- Specified by:
onLostControlin interfaceIBaritoneProcess
-
displayName0
- Specified by:
displayName0in interfaceIBaritoneProcess
-
mine
Begin to search for and mine the specified blocks.- Parameters:
filter- The blocks to mine
-
mineByName
Begin to search for and mine the specified blocks.- Parameters:
blocks- The blocks to mine
-
mine
Begin to search for and mine the specified blocks.- Parameters:
quantity- The total number of items to getblocks- The blocks to mine
-
mine
Begin to search for and mine the specified blocks.- Parameters:
blocks- The blocks to mine
-
cancel
public void cancel()Cancels the current mining task -
droppedItemsScan
-
searchWorld
public static List<BlockPos> searchWorld(CalculationContext ctx, BlockOptionalMetaLookup filter, int max, List<BlockPos> alreadyKnown, List<BlockPos> blacklist, List<BlockPos> dropped) -
plausibleToBreak
-
mineByName
-
mine
-