Module interact

Source

Structs§

CurrentSequenceNumber
A component that contains the number of changes this client has made to blocks.
HitResultComponent
A component that contains the block or entity that the player is currently looking at.
InteractPlugin
A plugin that allows clients to interact with blocks in the world.
StartUseItemEvent
An event that makes one of our clients simulate a right-click.
StartUseItemQueued
A component that makes our client simulate a right-click on the next GameTick. It’s removed after that tick.
SwingArmEvent
Swing your arm. This is purely a visual effect and won’t interact with anything in the world.

Functions§

can_use_game_master_blocks
check_block_can_be_broken_by_item_in_adventure_mode
Check if the item has the CanDestroy tag for the block.
check_is_interaction_restricted
Whether we can’t interact with the block, based on your gamemode. If this is false, then we can interact with the block.
handle_start_use_item_event
handle_start_use_item_queued
handle_swing_arm_event
handle_swing_arm_trigger
pick
Get the block or entity that a player would be looking at if their eyes were at the given direction and position.
pick_block
Get the block that a player would be looking at if their eyes were at the given direction and position.
update_hit_result_component