Raycasting Customizer

Creates a data pack using vdvman1's raycasting functions.

Use the following command to activate the raycast:

execute as <shooter> at @s anchored eyes positioned ^ ^ ^ anchored feet run function :start_ray

Go back

Customization options

Customize the namespace used with this data pack.

Customize the scoreboard objective used with this data pack.

Customize the tag applied to the player as they perform the raycast.

Detection

Select which type of detection to use.

Specify the maximum distance of the raycast in blocks.

Block

Select which type of block detection should be used.

Specify which blocks to use with the block detection method above.

Specify the commands you wish to run when block raycasting succeeds.

Tip: use scoreboard players set #hit 0 if you want the raycast to continue.

Entity

Select which types of entities should be detected. Leave blank for all entities.

Specify the commands you wish to run when entity raycasting succeeds. The entity can be targeted with @s and the execution position is at that entity. You can select the entity that performed the raycast by looking for an entity with the tag. For example: @a[tag=,limit=1]

Tip: use scoreboard players set #hit 0 if you want the raycast to continue.