public static class GantryShaftBlock.PlacementHelper extends PoleHelper<net.minecraft.util.Direction>
axisFunction, property, statePredicateID| Constructor and Description |
|---|
PlacementHelper() |
| Modifier and Type | Method and Description |
|---|---|
java.util.function.Predicate<net.minecraft.item.ItemStack> |
getItemPredicate() |
PlacementOffset |
getOffset(net.minecraft.entity.player.PlayerEntity player,
net.minecraft.world.World world,
net.minecraft.block.BlockState state,
net.minecraft.util.math.BlockPos pos,
net.minecraft.util.math.BlockRayTraceResult ray) |
attachedPoles, getStatePredicate, matchesAxisclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdisplayGhost, getOffset, matchesItem, matchesState, orderedByDistance, orderedByDistance, orderedByDistanceExceptAxis, orderedByDistanceExceptAxis, orderedByDistanceExceptAxis, orderedByDistanceExceptAxis, orderedByDistanceOnlyAxis, orderedByDistanceOnlyAxis, renderArrow, renderArrow, renderAtpublic java.util.function.Predicate<net.minecraft.item.ItemStack> getItemPredicate()
public PlacementOffset getOffset(net.minecraft.entity.player.PlayerEntity player, net.minecraft.world.World world, net.minecraft.block.BlockState state, net.minecraft.util.math.BlockPos pos, net.minecraft.util.math.BlockRayTraceResult ray)
getOffset in interface IPlacementHelpergetOffset in class PoleHelper<net.minecraft.util.Direction>player - the player that activated the placement helperworld - the world that the placement helper got activated instate - the Blockstate of the Block that the player is looking at or clicked onpos - the position of the Block the player is looking at or clicked onray - the exact raytrace resultPlacementOffset.fail() when no new position could be found.PlacementOffset.success(Vector3i) with the new BlockPos to indicate a success
and call PlacementOffset.withTransform(Function) if the blocks default state has to be modified before it is placed