Autonomous Cave Borrower

Build an automated cave carver in Minecraft that creates a block of layered stone and releases six glowing orbs to dig winding tunnels lined with crystals.

Java EditionComplex Contraptions & CinematicsHard24 commandsTested on a real 26.2 & 26.3 server
Glowing colored blocks emit cyan particles while carving tunnels through a layered stone and deepslate structure. Download the GIF Video & GIF © www.9minecraft.net

Self-building StructuresNatureMysticCyanPinkGreenBuilding ToolMap MakingBlock displaysBlock building (fill/setblock/clone)Rotation math21+ commands

The Autonomous Cave Borrower generates a massive chunk of layered stone, deepslate, and mossy cobblestone right in front of you, then releases six colourful glowing orbs inside it. As the orbs wander through the solid rock, they shatter the stone in their path, carving out open windows, winding tunnels, and caverns.

Watch through the carved openings as the orbs bounce from wall to wall, spraying cyan and purple sparks while leaving behind glowing amethyst clusters and sea lanterns to light up the newly formed cave system.

1. Setup - type these once 10 commands

  1. /scoreboard objectives add c9_timer dummy
  2. /fill ~-6 ~ ~-6 ~6 ~10 ~6 stone
  3. /fill ~-6 ~ ~-6 ~6 ~3 ~6 deepslate
  4. /fill ~-5 ~1 ~-5 ~5 ~9 ~5 tuff replace stone
  5. /fill ~-6 ~10 ~-6 ~6 ~10 ~6 mossy_cobblestone
  6. /fill ~-2 ~1 ~-6 ~2 ~8 ~6 air
  7. /summon block_display ~-4 ~6 ~-4 {Tags:["c9_borer","c9_a"],Rotation:[35f,0f],Glowing:1b,glow_color_override:65535,block_state:{Name:"minecraft:sea_lantern"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[0.9f,0.9f,0.9f],translation:[-0.45f,-0.45f,-0.45f]}}
  8. /summon block_display ~4 ~4 ~-4 {Tags:["c9_borer","c9_a"],Rotation:[145f,0f],Glowing:1b,glow_color_override:16744192,block_state:{Name:"minecraft:shroomlight"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[0.9f,0.9f,0.9f],translation:[-0.45f,-0.45f,-0.45f]}}
  9. /summon block_display ~ ~8 ~3 {Tags:["c9_borer","c9_a"],Rotation:[250f,0f],Glowing:1b,glow_color_override:16711935,block_state:{Name:"minecraft:amethyst_block"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[0.9f,0.9f,0.9f],translation:[-0.45f,-0.45f,-0.45f]}}
  10. /execute as @e[tag=c9_a] at @s run summon block_display ~ ~-2 ~1 {Tags:["c9_borer","c9_b"],Rotation:[80f,0f],Glowing:1b,glow_color_override:65280,block_state:{Name:"minecraft:ochre_froglight"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[0.9f,0.9f,0.9f],translation:[-0.45f,-0.45f,-0.45f]}}

2. Loop - one repeating command block each (Always Active) 14 commands

  1. /scoreboard players add @e[tag=c9_borer] c9_timer 1
  2. /execute as @e[tag=c9_a] at @s run tp @s ~ ~ ~ ~7 ~
  3. /execute as @e[tag=c9_b] at @s run tp @s ~ ~ ~ ~-9 ~
  4. /execute as @e[tag=c9_borer,scores={c9_timer=14}] at @s run tp @s ~ ~ ~ ~65 ~
  5. /execute as @e[tag=c9_borer,scores={c9_timer=28..}] run scoreboard players set @s c9_timer 0
  6. /execute as @e[tag=c9_borer] at @s rotated ~ 0 run tp @s ^ ^ ^0.45
  7. /execute as @e[tag=c9_a,scores={c9_timer=1..14}] at @s run tp @s ~ ~0.08 ~
  8. /execute as @e[tag=c9_a,scores={c9_timer=15..28}] at @s run tp @s ~ ~-0.09 ~
  9. /execute at @e[tag=c9_borer] run fill ~-1 ~ ~-1 ~1 ~2 ~1 air
  10. /execute as @e[tag=c9_borer,scores={c9_timer=1}] at @s run setblock ~ ~1 ~ air destroy
  11. /kill @e[type=item,distance=..22]
  12. /execute at @e[tag=c9_borer] run particle dust{color:[0.1,1.0,0.9],scale:2.0} ~ ~0.5 ~ 0.6 0.6 0.6 0 8 force
  13. /execute at @e[tag=c9_borer] run particle soul_fire_flame ~ ~0.5 ~ 0.4 0.4 0.4 0.04 4 force
  14. /execute as @e[tag=c9_borer] unless entity @s[distance=..6.5] run tp @s ~ ~5 ~ ~135 ~

How it works

Frames from the test run

Autonomous Cave Borrower - frame 1Autonomous Cave Borrower - frame 2Autonomous Cave Borrower - frame 3

Recorded on our own test server: 60 frames at about 9.9 fps. Our image check saw: Looking into a carved-out tunnel within a layered stone and deepslate block, where glowing magenta and green outlined cubes move around emitting bright cyan particles.

Commands, video and screenshots: tested and recorded by www.9minecraft.net © 9Minecraft. Sharing a video or screenshot? Please credit www.9minecraft.net.

Build it in your world

  1. Stand at the centre of a flat open area where you want the stone massif to appear.
  2. Run each of the 10 setup commands in order in chat, or place them in a chain of impulse command blocks.
  3. Place 14 repeating command blocks (or one repeating block feeding into 13 chain command blocks) at the exact same centre coordinates, or wrap them with execute positioned at the centre of the rock block.
  4. Paste one loop command into each block and set them all to Always Active.
  5. Step back and watch the six glowing orbs carve windows, arches, and caverns out of the solid stone.

Use it with real players

To let a player control the excavation manually, replace @e[tag=c9_borer] in the loop commands with @a[nbt={SelectedItem:{id:"minecraft:amethyst_shard"}}] and change the relative offsets to ^ ^1 ^4 so holding an amethyst shard carves tunnels wherever you look.

Remove it again 4 commands

  1. /kill @e[tag=c9_borer]
  2. /kill @e[type=item,distance=..25]
  3. /fill ~-7 ~ ~-7 ~7 ~12 ~7 air
  4. /scoreboard objectives remove c9_timer

FAQ

Will the broken blocks cause lag from dropped items?

No. Most of the carving uses /fill with air, and the periodic /setblock destroy effect is immediately cleaned up by a distance-limited /kill command targeting dropped items.

Can I make the cave system larger?

Yes. Increase the /fill dimensions in the first five setup commands and raise the distance check in the final loop command from 6.5 to match your new rock size.

Commands used

/execute/fill/kill/particle/scoreboard/setblock/summon/tp

Similar creations

Join 9Minecraft News & Guides