Six glowing builder cubes scatter across a deepslate slab, carve gilded rooms, and tunnel a fresh procedural quartz-road maze right before your eyes.
Self-building StructuresDarkMedievalBlackWhiteCyanMini-gameAdventure MapMap MakingBlock displaysSmooth animation (interpolation)Summoned mobsBlock building (fill/setblock/clone)Rotation math21+ commands
Watch a solid slab of deepslate bricks transform into a complete dungeon maze on its own. Six glowing block_display builders scatter randomly across the arena, hollow out 5x5 rooms floored with gilded blackstone, and then wander along orthogonal paths to carve connecting corridors paved with quartz bricks.
Using pure vanilla commands with /spreadplayers, /random, and smooth display-entity interpolation, every 11-second cycle generates a brand-new layout with cyan dust particles marking each tunnel as it opens.
/scoreboard objectives add c9tick dummy/scoreboard objectives add c9dir dummy/scoreboard players set #t c9tick 0/kill @e[tag=c9_room]/summon minecraft:block_display ~ ~2 ~ {Tags:["c9_room"],Glowing:1b,glow_color_override:65535,teleport_duration:2,block_state:{Name:"minecraft:sea_lantern"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.4f,0.2f,-0.4f],scale:[0.8f,0.8f,0.8f]}}/summon minecraft:block_display ~ ~2 ~ {Tags:["c9_room"],Glowing:1b,glow_color_override:16766720,teleport_duration:2,block_state:{Name:"minecraft:gold_block"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.4f,0.2f,-0.4f],scale:[0.8f,0.8f,0.8f]}}/summon minecraft:block_display ~ ~2 ~ {Tags:["c9_room"],Glowing:1b,glow_color_override:65535,teleport_duration:2,block_state:{Name:"minecraft:sea_lantern"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.4f,0.2f,-0.4f],scale:[0.8f,0.8f,0.8f]}}/summon minecraft:block_display ~ ~2 ~ {Tags:["c9_room"],Glowing:1b,glow_color_override:16766720,teleport_duration:2,block_state:{Name:"minecraft:gold_block"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.4f,0.2f,-0.4f],scale:[0.8f,0.8f,0.8f]}}/summon minecraft:block_display ~ ~2 ~ {Tags:["c9_room"],Glowing:1b,glow_color_override:16729343,teleport_duration:2,block_state:{Name:"minecraft:amethyst_block"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.4f,0.2f,-0.4f],scale:[0.8f,0.8f,0.8f]}}/summon minecraft:block_display ~ ~2 ~ {Tags:["c9_room"],Glowing:1b,glow_color_override:16729343,teleport_duration:2,block_state:{Name:"minecraft:amethyst_block"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.4f,0.2f,-0.4f],scale:[0.8f,0.8f,0.8f]}}/scoreboard players add #t c9tick 1/execute if score #t c9tick matches 221.. run scoreboard players set #t c9tick 1/execute if score #t c9tick matches 1 run fill ~-15 ~-1 ~-15 ~15 ~-1 ~15 minecraft:polished_deepslate/execute if score #t c9tick matches 1 run fill ~-15 ~ ~-15 ~15 ~1 ~15 minecraft:deepslate_bricks/execute if score #t c9tick matches 2 run spreadplayers ~ ~ 4 8 false @e[tag=c9_room]/execute if score #t c9tick matches 6 at @e[tag=c9_room] run fill ~-2 ~-2 ~-2 ~2 ~-1 ~2 minecraft:air/execute if score #t c9tick matches 7 at @e[tag=c9_room] run fill ~-2 ~-3 ~-2 ~2 ~-3 ~2 minecraft:gilded_blackstone/execute if score #t c9tick matches 12..190 as @e[tag=c9_room] store result score @s c9dir run random value 0..7/execute if score #t c9tick matches 12..190 as @e[tag=c9_room,scores={c9dir=0}] at @s run tp @s ~ ~ ~ ~90 0/execute if score #t c9tick matches 12..190 as @e[tag=c9_room,scores={c9dir=4..7}] at @s run tp @s ^ ^ ^1/execute if score #t c9tick matches 12..190 positioned ~ ~ ~ as @e[tag=c9_room,distance=13..] at @s run tp @s ^ ^ ^-1 ~180 0/execute if score #t c9tick matches 12..190 at @e[tag=c9_room] run fill ~ ~-2 ~ ~ ~-1 ~ minecraft:air/execute if score #t c9tick matches 12..190 at @e[tag=c9_room] if block ~ ~-3 ~ minecraft:polished_deepslate run setblock ~ ~-3 ~ minecraft:quartz_bricks/execute if score #t c9tick matches 12..190 at @e[tag=c9_room] run particle minecraft:dust{color:[0.1,0.9,1.0],scale:1.5} ~ ~-0.5 ~ 0.35 0.6 0.35 0.05 5 forcesetup #5 Summons a glowing sea lantern block_display cube with teleport_duration:2 so every movement and 90-degree turn glides smoothly.loop #5 On tick 2, spreadplayers scatters all six builders randomly onto the top of the 31x31 deepslate brick slab, keeping them at least 4 blocks apart.loop #6 On tick 6, each builder carves a 5x2x5 room straight out of the stone slab beneath it before the next command lays the gilded blackstone floor.loop #8 Uses /random value 0..7 on every builder each tick: 0 rotates 90 degrees, 4..7 steps one block forward, and 1..3 pauses to keep pacing readable.loop #11 Keeps every builder inside a 13-block radius by stepping any boundary-crossing marker back one block and flipping it 180 degrees inward.loop #13 Places quartz brick roads only over untouched polished_deepslate so corridors connect right up to room edges without overwriting gilded room floors.


Recorded on our own test server: 66 frames at about 9.4 fps. Our image check saw: Glowing colored block display entities with cyan particles move orthogonally through a deepslate brick slab, carving quartz-brick corridors between gilded blackstone rooms.
Commands, video and screenshots: tested and recorded by www.9minecraft.net © 9Minecraft. Sharing a video or screenshot? Please credit www.9minecraft.net.
To let players explore a finished maze without it resetting, remove the second loop command (scoreboard players set #t c9tick 1) and place a button on an impulse command block running /scoreboard players set #t c9tick 0 so players can generate a brand-new maze whenever they are ready.
/kill @e[tag=c9_room]/scoreboard objectives remove c9tick/scoreboard objectives remove c9dir/fill ~-15 ~-1 ~-15 ~15 ~-1 ~15 minecraft:grass_block/fill ~-15 ~ ~-15 ~15 ~3 ~15 minecraft:airHovering one block above the walls keeps the glowing cubes visible from an overhead view and prevents them from getting trapped inside their own 2-block-tall walls.
Yes. Expand the two reset /fill commands and increase the distance=13.. boundary check for a larger maze, or run additional setup /summon commands tagged c9_room to add more builders.
/execute/fill/kill/particle/random/scoreboard/setblock/spreadplayers/summon/tp
▶Automated Dungeon BuilderSelf-building StructuresHard26 cmds
▶Procedural Dungeon BuilderSelf-building StructuresHard26 cmds
▶Procedural Dungeon GeneratorSelf-building StructuresExpert24 cmds
▶Procedural Floating Dungeon ComplexSelf-building StructuresExpert24 cmds
▶Self-Building Dungeon MazeSelf-building StructuresHard24 cmds
▶Self-Building Procedural DungeonSelf-building StructuresExpert24 cmds