Block Detection

Started by bdzbasicbricks on

Topic category: Help with Minecraft modding (Java Edition)

Joined Aug 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Block Detection

So you know how leaves can tell if they're attached to a log, even through other leaves? I want to do something like this and am not sure how. I Basically need a certain kind of block (ill call it block 1) to be able to get the coordinates of any attached block of a specific type (block 2). Does anyone know how to do this?

Joined Mar 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
You can create a procedure…
Fri, 11/08/2024 - 20:23

You can create a procedure that tests all the blocks around a block and checks whether at least one is a definite block, and if none, replaces it with air after a random number of ticks.