How to detect if a path is valid?

Started by JamesAib on

Topic category: Help with Minecraft modding (Java Edition)

Joined Jan 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How to detect if a path is valid?

MCreator’s pathing tools are surprisingly limited. Right now, the only thing you can do is issue a “move to” or “attempt to path find to” command—you can’t actually verify whether a route is reachable, stop a path, or inspect the path in any way.

It seems like basic functionality, honestly and I haven’t been able to dig up any documentation or examples online that show otherwise (though I’d love to be proven wrong).

What I really need is a way, inside my EntityTickUpdate procedure, to ask, “Can this entity actually reach that target point?” without resorting to waiting a handful of ticks and checking if its distance decreases (which is hacky and inefficient). If anyone has ideas for a more direct check—or any clever workarounds

PLEASE send em my way :")

Joined Apr 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I don't have any suggestions…
Sat, 06/28/2025 - 15:43

I don't have any suggestions beyond the hacky ones you suggested. I just wanted to say that I would also like to know of a way to do this.

Not sure if you can do that,…
Sat, 06/28/2025 - 19:39

Not sure if you can do that, as pathfinding of the entities runs by its pathfinder, which only operates in close range and does not know if target is reachable in a given moment