-
Notifications
You must be signed in to change notification settings - Fork 0
Seeing the Path
Alexander Parent edited this page Jul 31, 2026
·
1 revision
"Why did it walk there?" is a question you can answer by looking.
PathDebugRenderer renderer = new PathDebugRenderer();
// From the tick thread, as often as you want to see it.
renderer.render(controller);Nodes are coloured by role:
| Colour | Meaning |
|---|---|
WAX_ON |
already walked |
HAPPY_VILLAGER |
still to walk |
FLAME |
the node it is heading for now |
ELECTRIC_SPARK |
reached by a jump or a climb |
Pick your own particles and density:
new PathDebugRenderer(
Particle.CRIT, // walked
Particle.END_ROD, // remaining
Particle.SOUL_FIRE_FLAME, // current
Particle.COMPOSTER, // jump or climb
2); // particles per nodeNavigationPlan plan = navigation.plan(request).join();
renderer.render(instance, plan);Particles go to everyone who can see the instance, and it is one packet group per node. Render the mob you are investigating, not all of them:
navigation.eventNode().addListener(PathComputedEvent.class, e -> {
if (e.getEntity().getUuid().equals(watched)) renderer.render(e.controller());
});Nothing about navigation depends on the renderer; it reads the published route and sends particles.
Start here
Shaping behaviour
Going deeper
Reference