Class TreeCutter
java.lang.Object
com.simibubi.create.content.kinetics.saw.TreeCutter
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleancanDynamicTreeCutFrom(net.minecraft.world.level.block.Block startBlock) static Optional<AbstractBlockBreakQueue> findDynamicTree(net.minecraft.world.level.block.Block startBlock, net.minecraft.core.BlockPos pos) static TreeCutter.TreefindTree(net.minecraft.world.level.BlockGetter reader, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState brokenState) Finds a tree at the given pos.static booleanisChorus(net.minecraft.world.level.block.state.BlockState stateAbove) static booleanisLog(net.minecraft.world.level.block.state.BlockState state) static booleanisRoot(net.minecraft.world.level.block.state.BlockState state) static booleanisVerticalPlant(net.minecraft.world.level.block.state.BlockState stateAbove)
-
Field Details
-
NO_TREE
-
-
Constructor Details
-
TreeCutter
public TreeCutter()
-
-
Method Details
-
canDynamicTreeCutFrom
public static boolean canDynamicTreeCutFrom(net.minecraft.world.level.block.Block startBlock) -
findDynamicTree
@Nonnull public static Optional<AbstractBlockBreakQueue> findDynamicTree(net.minecraft.world.level.block.Block startBlock, net.minecraft.core.BlockPos pos) -
findTree
@Nonnull public static TreeCutter.Tree findTree(@Nullable net.minecraft.world.level.BlockGetter reader, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState brokenState) Finds a tree at the given pos. Block at the position should be air- Parameters:
reader- the level that will be searched for a treepos- position that the saw cut atbrokenState- block state what was broken by the saw
-
isChorus
public static boolean isChorus(net.minecraft.world.level.block.state.BlockState stateAbove) -
isVerticalPlant
public static boolean isVerticalPlant(net.minecraft.world.level.block.state.BlockState stateAbove) -
isRoot
public static boolean isRoot(net.minecraft.world.level.block.state.BlockState state) -
isLog
public static boolean isLog(net.minecraft.world.level.block.state.BlockState state)
-