Uses of Enum Class
net.minecraft.world.InteractionResult
Packages that use InteractionResult
Package
Description
-
Uses of InteractionResult in net.minecraft.client.multiplayer
Methods in net.minecraft.client.multiplayer that return InteractionResultModifier and TypeMethodDescriptionMultiPlayerGameMode.interact
(Player player, Entity target, InteractionHand hand) Handles right-clicking an entity, sends a packet to the server.MultiPlayerGameMode.interactAt
(Player player, Entity target, EntityHitResult ray, InteractionHand hand) Handles right-clicking an entity from the entities side, sends a packet to the server.private InteractionResult
MultiPlayerGameMode.performUseItemOn
(LocalPlayer player, InteractionHand hand, BlockHitResult p_result) MultiPlayerGameMode.useItem
(Player player, InteractionHand hand) MultiPlayerGameMode.useItemOn
(LocalPlayer player, InteractionHand hand, BlockHitResult result) -
Uses of InteractionResult in net.minecraft.server.level
Methods in net.minecraft.server.level that return InteractionResultModifier and TypeMethodDescriptionDemoMode.useItem
(ServerPlayer player, Level level, ItemStack stack, InteractionHand hand) ServerPlayerGameMode.useItem
(ServerPlayer player, Level level, ItemStack stack, InteractionHand hand) DemoMode.useItemOn
(ServerPlayer player, Level level, ItemStack stack, InteractionHand hand, BlockHitResult hitResult) ServerPlayerGameMode.useItemOn
(ServerPlayer player, Level level, ItemStack stack, InteractionHand hand, BlockHitResult hitResult) -
Uses of InteractionResult in net.minecraft.server.network
Methods in net.minecraft.server.network that return InteractionResultModifier and TypeMethodDescriptionServerGamePacketListenerImpl.EntityInteraction.run
(ServerPlayer player, Entity entity, InteractionHand hand) -
Uses of InteractionResult in net.minecraft.world
Fields in net.minecraft.world declared as InteractionResultMethods in net.minecraft.world that return InteractionResultModifier and TypeMethodDescriptionInteractionResultHolder.getResult()
ItemInteractionResult.result()
static InteractionResult
InteractionResult.sidedSuccess
(boolean isClientSide) static InteractionResult
Returns the enum constant of this class with the specified name.static InteractionResult[]
InteractionResult.values()
Returns an array containing the constants of this enum class, in the order they are declared.Constructors in net.minecraft.world with parameters of type InteractionResult -
Uses of InteractionResult in net.minecraft.world.entity
Methods in net.minecraft.world.entity that return InteractionResultModifier and TypeMethodDescriptionprivate InteractionResult
Mob.checkAndHandleImportantInteractions
(Player player, InteractionHand hand) Entity.interact
(Player player, InteractionHand hand) Interaction.interact
(Player player, InteractionHand hand) final InteractionResult
Mob.interact
(Player player, InteractionHand hand) Entity.interactAt
(Player player, Vec3 vec, InteractionHand hand) Applies the given player interaction to this Entity.protected InteractionResult
Mob.mobInteract
(Player player, InteractionHand hand) -
Uses of InteractionResult in net.minecraft.world.entity.animal
Methods in net.minecraft.world.entity.animal that return InteractionResultModifier and TypeMethodDescriptionprotected InteractionResult
AbstractFish.mobInteract
(Player player, InteractionHand hand) Animal.mobInteract
(Player player, InteractionHand hand) Cat.mobInteract
(Player player, InteractionHand hand) Cow.mobInteract
(Player player, InteractionHand hand) protected InteractionResult
Dolphin.mobInteract
(Player player, InteractionHand hand) protected InteractionResult
IronGolem.mobInteract
(Player player, InteractionHand hand) MushroomCow.mobInteract
(Player player, InteractionHand hand) Ocelot.mobInteract
(Player player, InteractionHand hand) Panda.mobInteract
(Player player, InteractionHand hand) Parrot.mobInteract
(Player player, InteractionHand hand) Pig.mobInteract
(Player player, InteractionHand hand) Sheep.mobInteract
(Player player, InteractionHand hand) protected InteractionResult
SnowGolem.mobInteract
(Player player, InteractionHand hand) Wolf.mobInteract
(Player player, InteractionHand hand) Methods in net.minecraft.world.entity.animal that return types with arguments of type InteractionResultModifier and TypeMethodDescriptionstatic <T extends LivingEntity & Bucketable>
Optional<InteractionResult> Bucketable.bucketMobPickup
(Player player, InteractionHand hand, T entity) -
Uses of InteractionResult in net.minecraft.world.entity.animal.allay
Methods in net.minecraft.world.entity.animal.allay that return InteractionResultModifier and TypeMethodDescriptionprotected InteractionResult
Allay.mobInteract
(Player player, InteractionHand hand) -
Uses of InteractionResult in net.minecraft.world.entity.animal.armadillo
Methods in net.minecraft.world.entity.animal.armadillo that return InteractionResult -
Uses of InteractionResult in net.minecraft.world.entity.animal.axolotl
Methods in net.minecraft.world.entity.animal.axolotl that return InteractionResult -
Uses of InteractionResult in net.minecraft.world.entity.animal.camel
Methods in net.minecraft.world.entity.animal.camel that return InteractionResult -
Uses of InteractionResult in net.minecraft.world.entity.animal.frog
Methods in net.minecraft.world.entity.animal.frog that return InteractionResult -
Uses of InteractionResult in net.minecraft.world.entity.animal.goat
Methods in net.minecraft.world.entity.animal.goat that return InteractionResult -
Uses of InteractionResult in net.minecraft.world.entity.animal.horse
Methods in net.minecraft.world.entity.animal.horse that return InteractionResultModifier and TypeMethodDescriptionAbstractChestedHorse.mobInteract
(Player player, InteractionHand hand) AbstractHorse.mobInteract
(Player player, InteractionHand hand) Horse.mobInteract
(Player player, InteractionHand hand) SkeletonHorse.mobInteract
(Player player, InteractionHand hand) ZombieHorse.mobInteract
(Player player, InteractionHand hand) -
Uses of InteractionResult in net.minecraft.world.entity.animal.sniffer
Methods in net.minecraft.world.entity.animal.sniffer that return InteractionResult -
Uses of InteractionResult in net.minecraft.world.entity.decoration
Methods in net.minecraft.world.entity.decoration that return InteractionResultModifier and TypeMethodDescriptionItemFrame.interact
(Player player, InteractionHand hand) LeashFenceKnotEntity.interact
(Player player, InteractionHand hand) ArmorStand.interactAt
(Player player, Vec3 vec, InteractionHand hand) Applies the given player interaction to this Entity. -
Uses of InteractionResult in net.minecraft.world.entity.monster
Methods in net.minecraft.world.entity.monster that return InteractionResultModifier and TypeMethodDescriptionprotected InteractionResult
Bogged.mobInteract
(Player player, InteractionHand hand) protected InteractionResult
Creeper.mobInteract
(Player player, InteractionHand hand) Strider.mobInteract
(Player player, InteractionHand hand) ZombieVillager.mobInteract
(Player player, InteractionHand hand) -
Uses of InteractionResult in net.minecraft.world.entity.monster.hoglin
Methods in net.minecraft.world.entity.monster.hoglin that return InteractionResult -
Uses of InteractionResult in net.minecraft.world.entity.monster.piglin
Methods in net.minecraft.world.entity.monster.piglin that return InteractionResultModifier and TypeMethodDescriptionPiglin.mobInteract
(Player player, InteractionHand hand) static InteractionResult
PiglinAi.mobInteract
(Piglin piglin, Player player, InteractionHand hand) -
Uses of InteractionResult in net.minecraft.world.entity.npc
Methods in net.minecraft.world.entity.npc that return InteractionResultModifier and TypeMethodDescriptionVillager.mobInteract
(Player player, InteractionHand hand) WanderingTrader.mobInteract
(Player player, InteractionHand hand) -
Uses of InteractionResult in net.minecraft.world.entity.player
Methods in net.minecraft.world.entity.player that return InteractionResultModifier and TypeMethodDescriptionPlayer.interactOn
(Entity entityToInteractOn, InteractionHand hand) -
Uses of InteractionResult in net.minecraft.world.entity.vehicle
Methods in net.minecraft.world.entity.vehicle that return InteractionResultModifier and TypeMethodDescriptionAbstractMinecartContainer.interact
(Player player, InteractionHand hand) Boat.interact
(Player player, InteractionHand hand) ChestBoat.interact
(Player player, InteractionHand hand) Minecart.interact
(Player player, InteractionHand hand) MinecartChest.interact
(Player player, InteractionHand hand) MinecartCommandBlock.interact
(Player player, InteractionHand hand) MinecartFurnace.interact
(Player player, InteractionHand hand) default InteractionResult
ContainerEntity.interactWithContainerVehicle
(Player player) -
Uses of InteractionResult in net.minecraft.world.item
Methods in net.minecraft.world.item that return InteractionResultModifier and TypeMethodDescriptionstatic InteractionResult
LeadItem.bindPlayerMobs
(Player player, Level level, BlockPos pos) DyeItem.interactLivingEntity
(ItemStack stack, Player player, LivingEntity target, InteractionHand hand) Try interacting with given entity.Item.interactLivingEntity
(ItemStack stack, Player player, LivingEntity interactionTarget, InteractionHand usedHand) Try interacting with given entity.ItemStack.interactLivingEntity
(Player player, LivingEntity entity, InteractionHand usedHand) NameTagItem.interactLivingEntity
(ItemStack stack, Player player, LivingEntity target, InteractionHand hand) Try interacting with given entity.SaddleItem.interactLivingEntity
(ItemStack stack, Player player, LivingEntity target, InteractionHand hand) Try interacting with given entity.ShearsItem.interactLivingEntity
(ItemStack stack, Player player, LivingEntity entity, InteractionHand hand) Neo: Migrate shear behavior intoShearsItem.interactLivingEntity(net.minecraft.world.item.ItemStack, net.minecraft.world.entity.player.Player, net.minecraft.world.entity.LivingEntity, net.minecraft.world.InteractionHand)
to call into IShearable instead of relying onMob.mobInteract(net.minecraft.world.entity.player.Player, net.minecraft.world.InteractionHand)
private InteractionResult
ItemStack.onItemUse
(UseOnContext p_41662_, Function<UseOnContext, InteractionResult> callback) ItemStack.onItemUseFirst
(UseOnContext p_41662_) BlockItem.place
(BlockPlaceContext context) ArmorStandItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockAxeItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockBlockItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockBoneMealItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockBrushItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockCompassItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockDebugStickItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockEndCrystalItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockEnderEyeItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockFireChargeItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockFireworkRocketItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockFlintAndSteelItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockHangingEntityItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockHoeItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockHoneycombItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockItemStack.useOn
(UseOnContext context) LeadItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockMapItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockMinecartItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockPlaceOnWaterBlockItem.useOn
(UseOnContext p_220229_) PotionItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockShearsItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockShovelItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockSolidBucketItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockSpawnEggItem.useOn
(UseOnContext context) Called when this item is used when targeting a BlockMethod parameters in net.minecraft.world.item with type arguments of type InteractionResultModifier and TypeMethodDescriptionprivate InteractionResult
ItemStack.onItemUse
(UseOnContext p_41662_, Function<UseOnContext, InteractionResult> callback) -
Uses of InteractionResult in net.minecraft.world.level
Methods in net.minecraft.world.level that return InteractionResult -
Uses of InteractionResult in net.minecraft.world.level.block
Methods in net.minecraft.world.level.block that return InteractionResultModifier and TypeMethodDescriptionprotected static InteractionResult
CakeBlock.eat
(LevelAccessor level, BlockPos pos, BlockState state, Player player) static InteractionResult
CaveVines.use
(Entity entity, BlockState state, Level level, BlockPos pos) protected InteractionResult
AbstractFurnaceBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
AnvilBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
BarrelBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
BeaconBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
BedBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
BellBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
BrewingStandBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
ButtonBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
CakeBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
CandleCakeBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
CartographyTableBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
CaveVinesBlock.useWithoutItem
(BlockState p_152980_, Level p_152981_, BlockPos p_152982_, Player p_152983_, BlockHitResult p_152985_) protected InteractionResult
CaveVinesPlantBlock.useWithoutItem
(BlockState p_153021_, Level p_153022_, BlockPos p_153023_, Player p_153024_, BlockHitResult p_153026_) protected InteractionResult
ChestBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
ChiseledBookShelfBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
CommandBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
ComparatorBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
ComposterBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
CrafterBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
CraftingTableBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
DaylightDetectorBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
DecoratedPotBlock.useWithoutItem
(BlockState p_316866_, Level p_316544_, BlockPos p_316541_, Player p_316732_, BlockHitResult p_316860_) protected InteractionResult
DispenserBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
DoorBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
DragonEggBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
EnchantingTableBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
EnderChestBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
FenceBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
FenceGateBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
FletchingTableBlock.useWithoutItem
(BlockState p_53501_, Level p_53502_, BlockPos p_53503_, Player p_53504_, BlockHitResult p_53506_) protected InteractionResult
FlowerPotBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
GrindstoneBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
HopperBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
JigsawBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
JukeboxBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
LecternBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
LeverBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
LightBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
LoomBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
NoteBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
RedStoneWireBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
RepeaterBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
RespawnAnchorBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
ShulkerBoxBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
SignBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
SmithingTableBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
StonecutterBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
StructureBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
SweetBerryBushBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) protected InteractionResult
TrapDoorBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) -
Uses of InteractionResult in net.minecraft.world.level.block.piston
Methods in net.minecraft.world.level.block.piston that return InteractionResultModifier and TypeMethodDescriptionprotected InteractionResult
MovingPistonBlock.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) -
Uses of InteractionResult in net.minecraft.world.level.block.state
Methods in net.minecraft.world.level.block.state that return InteractionResultModifier and TypeMethodDescriptionBlockBehaviour.BlockStateBase.useWithoutItem
(Level level, Player player, BlockHitResult hitResult) protected InteractionResult
BlockBehaviour.useWithoutItem
(BlockState state, Level level, BlockPos pos, Player player, BlockHitResult hitResult) -
Uses of InteractionResult in net.neoforged.neoforge.common
Methods in net.neoforged.neoforge.common that return InteractionResultModifier and TypeMethodDescriptionstatic @Nullable InteractionResult
CommonHooks.onInteractEntity
(Player player, Entity entity, InteractionHand hand) static @Nullable InteractionResult
CommonHooks.onInteractEntityAt
(Player player, Entity entity, HitResult ray, InteractionHand hand) static @Nullable InteractionResult
CommonHooks.onInteractEntityAt
(Player player, Entity entity, Vec3 vec3d, InteractionHand hand) static @Nullable InteractionResult
CommonHooks.onItemRightClick
(Player player, InteractionHand hand) static InteractionResult
CommonHooks.onPlaceItemIntoWorld
(UseOnContext context) -
Uses of InteractionResult in net.neoforged.neoforge.common.extensions
Methods in net.neoforged.neoforge.common.extensions that return InteractionResultModifier and TypeMethodDescriptiondefault InteractionResult
IItemExtension.onItemUseFirst
(ItemStack stack, UseOnContext context) This is called when the item is used, before the block is activated.default InteractionResult
IItemStackExtension.onItemUseFirst
(UseOnContext context) -
Uses of InteractionResult in net.neoforged.neoforge.event.entity.player
Fields in net.neoforged.neoforge.event.entity.player declared as InteractionResultModifier and TypeFieldDescriptionprivate InteractionResult
PlayerInteractEvent.EntityInteract.cancellationResult
private InteractionResult
PlayerInteractEvent.EntityInteractSpecific.cancellationResult
private InteractionResult
PlayerInteractEvent.RightClickBlock.cancellationResult
private InteractionResult
PlayerInteractEvent.RightClickItem.cancellationResult
Methods in net.neoforged.neoforge.event.entity.player that return InteractionResultModifier and TypeMethodDescriptionPlayerInteractEvent.EntityInteract.getCancellationResult()
PlayerInteractEvent.EntityInteractSpecific.getCancellationResult()
PlayerInteractEvent.RightClickBlock.getCancellationResult()
PlayerInteractEvent.RightClickItem.getCancellationResult()
Methods in net.neoforged.neoforge.event.entity.player with parameters of type InteractionResultModifier and TypeMethodDescriptionvoid
PlayerInteractEvent.EntityInteract.setCancellationResult
(InteractionResult result) Set the InteractionResult that will be returned to vanilla if the event is cancelled, instead of calling the relevant method of the event.void
PlayerInteractEvent.EntityInteractSpecific.setCancellationResult
(InteractionResult result) Set the InteractionResult that will be returned to vanilla if the event is cancelled, instead of calling the relevant method of the event.void
PlayerInteractEvent.RightClickBlock.setCancellationResult
(InteractionResult result) Set the InteractionResult that will be returned to vanilla if the event is cancelled, instead of calling the relevant method of the event.void
PlayerInteractEvent.RightClickItem.setCancellationResult
(InteractionResult result) Set the InteractionResult that will be returned to vanilla if the event is cancelled, instead of calling the relevant method of the event.