Watch a glowing autonomous navigator weave through shifting neon barrier walls toward a moving beacon target using vanilla mob pathfinding AI.
Custom MobsTechnologyCyanWhiteLearningMini-gameMap MakingBlock displaysArmor standsSummoned mobsBlock building (fill/setblock/clone)21+ commands
Building a pathfinding system from scratch in vanilla Minecraft usually takes hundreds of command blocks, unless you let the game's own AI do the math for you. This creation drops a custom glowing navigator onto a neon arena where iron barrier walls shift positions every few seconds and the target beacon teleports around the room.
By placing an invisible lure at the goal and letting an iron golem's built-in obstacle avoidance take the wheel, the navigator smoothly calculates real-time routes around the shifting walls while leaving a bright cyan trail behind it.
/scoreboard objectives add c9_timer dummy/fill ~-9 ~-1 ~-9 ~9 ~-1 ~9 minecraft:polished_deepslate/fill ~-9 ~ ~-9 ~9 ~1 ~9 minecraft:sea_lantern hollow/fill ~-8 ~ ~-8 ~8 ~1 ~8 minecraft:air/fill ~-3 ~ ~-8 ~-3 ~1 ~2 minecraft:iron_bars/fill ~3 ~ ~-2 ~3 ~1 ~8 minecraft:iron_bars/summon minecraft:armor_stand ~6 ~ ~6 {Tags:["c9_entity","c9_goal"],Invisible:1b,NoGravity:1b,Marker:1b}/summon minecraft:block_display ~6 ~ ~6 {Tags:["c9_entity","c9_goal_vis"],Glowing:1b,glow_color_override:65535,block_state:{Name:"minecraft:beacon"},transformation:{translation:[-0.4f,0.1f,-0.4f],scale:[0.8f,0.8f,0.8f],left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f]}}/summon minecraft:iron_golem ~-6 ~ ~-6 {Tags:["c9_entity","c9_nav"],CustomName:{"text":"Navigator","color":"aqua"},CustomNameVisible:1b,Glowing:1b,Invulnerable:1b,Silent:1b,attributes:[{id:"minecraft:movement_speed",base:0.38d},{id:"minecraft:scale",base:0.55d},{id:"minecraft:follow_range",base:48.0d}]}/summon minecraft:zombie ~6 ~ ~6 {Tags:["c9_entity","c9_lure"],Silent:1b,Invulnerable:1b,NoAI:1b,NoGravity:1b,active_effects:[{id:"minecraft:invisibility",amplifier:0,duration:-1,show_particles:0b}],attributes:[{id:"minecraft:scale",base:0.2d}]}/scoreboard players add #tick c9_timer 1/execute if score #tick c9_timer matches 160.. run scoreboard players set #tick c9_timer 0/execute if score #tick c9_timer matches 1 run fill ~-8 ~ ~-8 ~8 ~1 ~8 minecraft:air replace minecraft:iron_bars/execute if score #tick c9_timer matches 1 run fill ~-3 ~ ~-8 ~-3 ~1 ~2 minecraft:iron_bars keep/execute if score #tick c9_timer matches 1 run fill ~3 ~ ~-2 ~3 ~1 ~8 minecraft:iron_bars keep/execute if score #tick c9_timer matches 1 run tp @e[tag=c9_goal,limit=1] ~6 ~ ~6/execute if score #tick c9_timer matches 81 run fill ~-8 ~ ~-8 ~8 ~1 ~8 minecraft:air replace minecraft:iron_bars/execute if score #tick c9_timer matches 81 run fill ~-8 ~ ~-2 ~2 ~1 ~-2 minecraft:iron_bars keep/execute if score #tick c9_timer matches 81 run fill ~-2 ~ ~3 ~8 ~1 ~3 minecraft:iron_bars keep/execute if score #tick c9_timer matches 81 run tp @e[tag=c9_goal,limit=1] ~-6 ~ ~6/execute at @e[tag=c9_goal,limit=1] run tp @e[tag=c9_goal_vis,limit=1] ~ ~ ~/execute at @e[tag=c9_goal,limit=1] run tp @e[tag=c9_lure,limit=1] ~ ~ ~/execute at @e[tag=c9_goal,limit=1] run particle minecraft:end_rod ~ ~1 ~ 0.25 0.6 0.25 0.02 3/execute at @e[tag=c9_nav,limit=1] run particle minecraft:dust{color:[0.0,1.0,1.0],scale:1.5} ~ ~0.4 ~ 0.15 0.1 0.15 0 4setup #1 Creates the <code>c9_timer</code> scoreboard objective to control when the arena walls rearrange and where the beacon teleports.setup #9 Summons a miniaturized, glowing Iron Golem named Navigator with boosted movement speed and a 48-block follow range so it always detects the target across the arena.setup #10 Summons a tiny invisible, invulnerable Zombie with <code>NoAI:1b</code> that acts as a lure at the target beacon for the Iron Golem's built-in pathfinding AI.loop #3 On tick 1 of each 8-second cycle, clears out old iron bar walls so a fresh obstacle layout can be placed.loop #8 Halfway through the cycle at tick 81, switches the iron bar walls from north-south barriers to east-west barriers and moves the goal to another corner.loop #12 Keeps the invisible lure entity locked onto the goal marker so the navigator immediately recalculates its path whenever the goal moves.loop #14 Draws a bright cyan dust trail behind the navigator as it maneuvers around the iron bar obstacles.


Recorded on our own test server: 58 frames at about 9.6 fps. Our image check saw: A glowing iron golem stands inside a sea lantern arena where iron bar walls change orientation and a beacon teleports from one corner to another.
Commands, video and screenshots: tested and recorded by www.9minecraft.net © 9Minecraft. Sharing a video or screenshot? Please credit www.9minecraft.net.
To make the navigator pathfind toward a real player instead of the automated beacon, replace @e[tag=c9_goal,limit=1] in the loop teleport commands with @p. The invisible lure will follow you wherever you walk, and the navigator will steer around walls and obstacles to reach your position.
/kill @e[tag=c9_entity]/scoreboard objectives remove c9_timer/fill ~-9 ~ ~-9 ~9 ~2 ~9 minecraft:air/fill ~-9 ~-1 ~-9 ~9 ~-1 ~9 minecraft:grass_blockVillagers flee from nearby zombies in a straight line and can get stuck in corners, whereas an Iron Golem actively calculates a full A* path around walls across long distances to reach its target.
Both the zombie and the golem are set to Invulnerable, and the zombie is shrunk down to 0.2 scale while the goal teleports to a new corner every 4 seconds as the navigator approaches.
▶Thread-Spinning Loom Weaver BossCustom MobsExpert23 cmds
▶Da Vinci Ornithopter Griffin AutomatonCustom MobsExpert24 cmds
▶Neon Cyberpunk Hologram KitsuneCustom MobsHard24 cmds
▶Prismatic Stained-Glass Peacock UnfurlingCustom MobsHard24 cmds
▶Steampunk Espresso Machine GolemCustom MobsHard23 cmds
▶Sub-Atomic Electron Cloud ElementalCustom MobsHard24 cmds