#Block position of player view

8 messages · Page 1 of 1 (latest)

pseudo python
#

I'm new to fabric coding and I wanted to know how would I create a method that gets the block coordinates of a block a player is looking at, maybe within 1000 blocks

violet viper
#

that's like something 62 chunks away. how can you guarantee that distance is visible to the player or if those chunks are loaded?

pseudo python
#

You're right, I'm just looking for visible blocks. 1000 blocks was just a random number

violet viper
#

do you want this information on the client or server?

pseudo python
#

Probably Client since the information is for the player

violet viper
#

the crosshair target has the looking at block

#

although the distance might be limited

chrome storm
#

if you need to go further you can use Entity#raycast