Interface InteractionEvent.RightClickBlock
- Enclosing interface:
- InteractionEvent
public static interface InteractionEvent.RightClickBlock
-
Method Summary
Modifier and TypeMethodDescriptionclick(net.minecraft.world.entity.player.Player player, net.minecraft.world.InteractionHand hand, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction face) Invoked whenever a player right clicks a block.
-
Method Details
-
click
EventResult click(net.minecraft.world.entity.player.Player player, net.minecraft.world.InteractionHand hand, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction face) Invoked whenever a player right clicks a block. Equivalent to Forge'sPlayerInteractEvent.RightClickBlockevent and Fabric'sUseBlockCallback.- Parameters:
player- The player right clicking the block.hand- The hand that is used.pos- The position of the block in the level.face- The face of the block clicked.- Returns:
- A
EventResultdetermining the outcome of the event, the action may be cancelled by the result.
-