public interface SensitiveConnectionPredicate extends ConnectionPredicate
ConnectionPredicate which by default makes the connection predicate sensitive.
Created 22/02/2024 by SuperMartijn642
| Modifier and Type | Method and Description |
|---|---|
default boolean |
isSensitive()
Determines whether this connection predicate depends on the level and should always be reevaluated.
|
default boolean |
shouldConnect(net.minecraft.util.EnumFacing side,
net.minecraft.block.state.IBlockState ownState,
net.minecraft.block.state.IBlockState otherState,
net.minecraft.block.state.IBlockState blockInFront,
ConnectionDirection direction)
Determines whether the model should connect to the given direction.
|
boolean |
shouldConnect(net.minecraft.world.IBlockAccess level,
net.minecraft.util.math.BlockPos pos,
net.minecraft.util.EnumFacing side,
net.minecraft.block.state.IBlockState ownState,
net.minecraft.block.state.IBlockState otherState,
net.minecraft.block.state.IBlockState blockInFront,
ConnectionDirection direction)
Determines whether the model should connect to the given direction.
|
and, getSerializer, negate, ordefault boolean shouldConnect(net.minecraft.util.EnumFacing side,
@Nullable
net.minecraft.block.state.IBlockState ownState,
net.minecraft.block.state.IBlockState otherState,
net.minecraft.block.state.IBlockState blockInFront,
ConnectionDirection direction)
ConnectionPredicateshouldConnect in interface ConnectionPredicateside - side of the block which the relevant texture is onownState - state of the block itselfotherState - state of the block in the connection directionblockInFront - state in front of otherstatedirection - direction to checktrue if the texture should connect in the given directionboolean shouldConnect(net.minecraft.world.IBlockAccess level,
net.minecraft.util.math.BlockPos pos,
net.minecraft.util.EnumFacing side,
@Nullable
net.minecraft.block.state.IBlockState ownState,
net.minecraft.block.state.IBlockState otherState,
net.minecraft.block.state.IBlockState blockInFront,
ConnectionDirection direction)
ConnectionPredicateConnectionPredicate.shouldConnect(EnumFacing, IBlockState, IBlockState, IBlockState, ConnectionDirection).
If this method should be used, ConnectionPredicate.isSensitive() must return true.shouldConnect in interface ConnectionPredicateside - side of the block which the relevant texture is onownState - state of the block itselfotherState - state of the block in the connection directionblockInFront - state in front of otherstatedirection - direction to checktrue if the texture should connect in the given directiondefault boolean isSensitive()
ConnectionPredicatetrue is returned ConnectionPredicate.shouldConnect(EnumFacing, IBlockState, IBlockState, IBlockState, ConnectionDirection) may throw an IllegalStateException.
If false is returned, it is assumed that the connection predicate may be cached for the values supplied in ConnectionPredicate.shouldConnect(EnumFacing, IBlockState, IBlockState, IBlockState, ConnectionDirection).isSensitive in interface ConnectionPredicateSensitiveConnectionPredicate