Build an automated industrial laser quarry in vanilla Minecraft that sweeps a high-energy redstone laser beam across an ore deposit and mines blocks.
Spawners & GeneratorsIndustrialTechnologyRedWhiteGoldBuilding ToolDecorationMap MakingBlock displaysArmor standsRiding & passengersBlock building (fill/setblock/clone)Sounds21+ commands
This command creation builds a working industrial laser quarry right on your stage. A glowing redstone laser housing slides back and forth across a heavy iron frame suspended above a rich deposit of stone, gold, diamond, and emerald ores.
As the gantry moves across the rails, it fires a thick, glowing red laser beam and particle stream down into the quarry pit. Every block struck by the laser vaporizes in a shower of sparks and drops its items, automatically resetting once the pit is cleared.
/scoreboard objectives add c9_q dummy/fill ~-5 ~ ~-5 ~5 ~7 ~5 iron_block outline/fill ~-4 ~ ~-5 ~4 ~6 ~5 air/fill ~-5 ~ ~-4 ~5 ~6 ~4 air/fill ~-4 ~7 ~-4 ~4 ~7 ~4 iron_bars/fill ~-3 ~ ~-3 ~3 ~3 ~3 stone/fill ~-2 ~1 ~-2 ~2 ~3 ~2 diamond_ore/fill ~-1 ~2 ~-1 ~1 ~3 ~1 emerald_ore/summon armor_stand ~-3 ~3 ~-3 {Tags:["c9_q","c9_miner"],Invisible:1b,NoGravity:1b,Marker:1b}/summon block_display ~-3 ~6.5 ~-3 {Tags:["c9_q","c9_head"],Glowing:1b,glow_color_override:16711680,block_state:{Name:"minecraft:redstone_block"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[1.2f,1.2f,1.2f],translation:[-0.6f,0f,-0.6f]},Passengers:[{id:"minecraft:block_display",Tags:["c9_q","c9_beam"],Glowing:1b,glow_color_override:16724787,block_state:{Name:"minecraft:red_stained_glass"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[0.35f,5.5f,0.35f],translation:[-0.175f,-5.5f,-0.175f]}}]}/scoreboard players add #t c9_q 1/execute if score #t c9_q matches 3.. run scoreboard players set #t c9_q 0/execute as @e[tag=c9_miner] at @s run particle dust{color:[1.0,0.1,0.1],scale:2.0} ~ ~2 ~ 0.08 1.8 0.08 0 25 force/execute as @e[tag=c9_miner] at @s run particle flame ~ ~0.5 ~ 0.15 0.3 0.15 0.02 6 force/execute if score #t c9_q matches 0 as @e[tag=c9_miner] at @s unless block ~ ~ ~ air run particle lava ~ ~0.5 ~ 0.2 0.2 0.2 0 8 force/execute if score #t c9_q matches 0 as @e[tag=c9_miner] at @s unless block ~ ~ ~ air run playsound block.amethyst_block.chime master @a ~ ~ ~ 0.8 1.6/execute if score #t c9_q matches 0 as @e[tag=c9_miner] at @s unless block ~ ~ ~ air run setblock ~ ~ ~ air destroy/execute if score #t c9_q matches 0 as @e[tag=c9_miner] at @s run scoreboard players add #x c9_q 1/execute if score #t c9_q matches 0 as @e[tag=c9_miner] at @s run tp @s ~1 ~ ~/execute if score #t c9_q matches 0 if score #x c9_q matches 7.. as @e[tag=c9_miner] at @s run tp @s ~-7 ~ ~1/execute if score #t c9_q matches 0 if score #x c9_q matches 7.. run scoreboard players add #z c9_q 1/execute if score #t c9_q matches 0 if score #x c9_q matches 7.. run scoreboard players set #x c9_q 0/execute if score #t c9_q matches 0 if score #z c9_q matches 7.. as @e[tag=c9_miner] at @s run tp @s ~ ~-1 ~-7/execute if score #t c9_q matches 0 if score #z c9_q matches 7.. run scoreboard players set #z c9_q 0setup #2 Builds the outer iron frame of the quarry using <code>/fill ... outline</code>, while the following commands hollow out the sides to leave four sturdy corner pillars and a roof frame.setup #10 Summons the glowing redstone gantry head along with a stretched <code>block_display</code> passenger made of red stained glass that acts as a solid, glowing laser core.loop #3 Generates a dense vertical column of bright red dust particles around the mining laser every tick so the beam looks energized.loop #7 Breaks the targeted block using <code>/setblock ~ ~ ~ air destroy</code> every 3 ticks, spawning block breaking particles, sound effects, and item drops.loop #10 Uses scoreboard counters <code>#x</code> and <code>#z</code> to step the mining point across the 7x7 quarry grid row by row, then drops down one layer when a full horizontal slice is finished.


Recorded on our own test server: 59 frames at about 9.8 fps. Our image check saw: An iron block gantry frame stands over a cube of stone and ores, while a glowing red laser mechanism on top fires red particles downward to mine away layers of blocks.
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 relocate the quarry anywhere in survival or creative mode, summon the c9_miner marker at a named armor stand or drop item thrown by a player, and run the /fill setup commands relative to that marker.
/kill @e[tag=c9_q]/kill @e[type=item,distance=..15]/fill ~-5 ~ ~-5 ~5 ~8 ~5 air/scoreboard objectives remove c9_qIn the second loop command, change <code>matches 3..</code> to a higher number like <code>10..</code> for slower mining, or <code>1..</code> to mine a block every single tick.
Yes! Because the command uses <code>setblock ~ ~ ~ air destroy</code>, every ore block breaks naturally and drops its items on the quarry floor for hoppers or players to collect.
/execute/fill/particle/playsound/scoreboard/setblock/summon/tp
▶Tesla Coil Lightning Arc SpawnerSpawners & GeneratorsMedium24 cmds
▶3D Conveyor Belt LoopSpawners & GeneratorsMedium26 cmds
▶Automated Conveyor AssemblySpawners & GeneratorsEasy24 cmds
▶Automated Conveyor FactorySpawners & GeneratorsEasy24 cmds
▶Automated Crop HarvesterSpawners & GeneratorsMedium24 cmds
▶Automated Factory Assembly LineSpawners & GeneratorsMedium24 cmds