How to detect in the procedure that the player is looking at a specific block?

Started by Wtf_Err0R on

Topic category: Help with modding (Java Edition)

Last seen on 13:30, 10. Jul 2024
Joined Sep 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How to detect in the procedure that the player is looking at a specific block?

I checked (getblockat [x] [y] [z] = {my block}) and (getblockat [x]valueoflook... [y]valueoflook... [z]valueoflook... = {my block})

Last seen on 17:28, 24. Jul 2024
Joined Oct 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Use, is entity looking at…
Mon, 12/11/2023 - 21:08

Use, is entity looking at block with raycasting distance of __.

Last seen on 13:30, 10. Jul 2024
Joined Sep 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
(is entity looking at block…
Tue, 12/12/2023 - 10:59

(is entity looking at block with raycasting distance of __.) is checking ANY block at ~ distance, I need it to check if the player is looking at the block I SPECIFIED like [is entity looking at Stone]

Last seen on 17:28, 24. Jul 2024
Joined Oct 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Is block raycasting = your…
Tue, 12/12/2023 - 11:39

Is block raycasting = your block

Last seen on 17:28, 24. Jul 2024
Joined Oct 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
if raycasting of player is…
Tue, 12/12/2023 - 11:40

if raycasting of player is the same block as your block, do what ever you want