Jump to content

Recommended Posts

Posted

Is there some method to get the Block, coordinates and distance form player when we right click an item?

 

For example on a Pickaxe when a player right clicks it I need to know what block is he pointing at, the coordinates and the distance to that block from the player.

 

Not sure if is there some Vanilla item with this behavior I can take a look at.

 

Thanks a lot for any help ;)

 

Posted

Thanks diesieben07 gonna take a look at that one ;)

 

I thought that only worked if the block was "in range" like the range when you place a block, I didn't know you can actually get the block and coordinates, no matter what the distance is ;)

 

Thanks one again.

Posted

Ohhh then I think think it will work for what I need.

 

I think the Wither has something that "aims" to blocks at any distance. Not sure if that can be applied to a player when right clicking an item  ???

 

Maybe some other method...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.