Class CauldronInteractions
java.lang.Object
net.minecraft.core.cauldron.CauldronInteractions
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<CauldronInteraction.Dispatcher> static final CauldronInteraction.Dispatcherprivate static final ExtraCodecs.LateBoundIdMapper<String, CauldronInteraction.Dispatcher> static final CauldronInteraction.Dispatcherstatic final CauldronInteraction.Dispatcherstatic final CauldronInteraction.Dispatcher -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static voidaddDefaultInteractions(CauldronInteraction.Dispatcher interactionMap) static InteractionResultbannerInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) static voidstatic InteractionResultdyedItemIteration(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) static InteractionResultemptyBucket(Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand, BlockState newState, SoundEvent soundEvent) static InteractionResultfillBucket(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand, ItemStack newItem, Predicate<BlockState> canFill, SoundEvent soundEvent) static InteractionResultfillLavaInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) static InteractionResultfillPowderSnowInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) static InteractionResultfillWaterInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) private static booleanisUnderWater(Level level, BlockPos pos) private static CauldronInteraction.DispatchernewDispatcher(String name) Deprecated.static voidstatic InteractionResultshulkerBoxInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand)
-
Field Details
-
ID_MAPPER
private static final ExtraCodecs.LateBoundIdMapper<String, CauldronInteraction.Dispatcher> ID_MAPPER -
CODEC
-
EMPTY
-
WATER
-
LAVA
-
POWDER_SNOW
-
-
Constructor Details
-
CauldronInteractions
public CauldronInteractions()
-
-
Method Details
-
newDispatcher
Deprecated.Neo: UseRegisterCauldronInteractionEvent.Dispatcherinstead -
registerCustomInteractions
-
bootStrap
public static void bootStrap() -
addDefaultInteractions
-
fillBucket
public static InteractionResult fillBucket(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand, ItemStack newItem, Predicate<BlockState> canFill, SoundEvent soundEvent) -
emptyBucket
public static InteractionResult emptyBucket(Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand, BlockState newState, SoundEvent soundEvent) -
fillWaterInteraction
public static InteractionResult fillWaterInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) -
fillLavaInteraction
public static InteractionResult fillLavaInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) -
fillPowderSnowInteraction
public static InteractionResult fillPowderSnowInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) -
shulkerBoxInteraction
public static InteractionResult shulkerBoxInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) -
bannerInteraction
public static InteractionResult bannerInteraction(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) -
dyedItemIteration
public static InteractionResult dyedItemIteration(BlockState state, Level level, BlockPos pos, Player player, InteractionHand hand, ItemStack itemInHand) -
isUnderWater
-
RegisterCauldronInteractionEvent.Dispatcherinstead