Custom block-display sweeper robots automatically collect arena debris while a central automated laser sentry turret tracks and zaps nearby intruders.
Factories & MachinesTechnologyIndustrialCyanRedWhiteMap MakingMini-gameDecorationBlock displaysArmor standsSummoned mobsBlock building (fill/setblock/clone)Rotation math21+ commands
This command creation builds a sci-fi security test pad right in your world. Three custom-modeled robotic sweepers patrol the floor, automatically steering toward dropped debris and vacuuming it up with cyan particle bursts. In the center of the arena stands an elevated automated sentry turret with a glowing core that tracks an intruder drone circling the perimeter, firing high-energy crimson laser pulses whenever it locks on.
/scoreboard objectives add c9_t dummy/fill ~-9 ~-1 ~-9 ~9 ~-1 ~9 minecraft:iron_block/fill ~-9 ~-1 ~-9 ~9 ~-1 ~9 minecraft:polished_deepslate replace minecraft:iron_block/fill ~-7 ~-1 ~-7 ~7 ~-1 ~7 minecraft:quartz_bricks/setblock ~ ~ ~ minecraft:lodestone/summon minecraft:block_display ~ ~1 ~ {Tags:["c9_all","c9_turret"],Glowing:1b,glow_color_override:16724787,block_state:{Name:"minecraft:observer"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[1.2f,1.2f,1.2f],translation:[-0.6f,-0.5f,-0.6f]}}/summon minecraft:armor_stand ~6 ~0.5 ~ {Tags:["c9_all","c9_target"],NoGravity:1b,Small:1b,Glowing:1b,armor_items:[{},{},{},{id:"minecraft:redstone_block",count:1}],CustomName:'{"text":"Intruder Drone","color":"red"}',CustomNameVisible:1b}/summon minecraft:block_display ~-4 ~0.1 ~-4 {Tags:["c9_all","c9_sweep"],Glowing:1b,glow_color_override:5636095,block_state:{Name:"minecraft:sea_lantern"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[0.9f,0.35f,0.9f],translation:[-0.45f,0f,-0.45f]}}/summon minecraft:block_display ~4 ~0.1 ~-4 {Tags:["c9_all","c9_sweep"],Glowing:1b,glow_color_override:5636095,block_state:{Name:"minecraft:sea_lantern"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[0.9f,0.35f,0.9f],translation:[-0.45f,0f,-0.45f]}}/summon minecraft:block_display ~ ~0.1 ~5 {Tags:["c9_all","c9_sweep"],Glowing:1b,glow_color_override:5636095,block_state:{Name:"minecraft:sea_lantern"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],scale:[0.9f,0.35f,0.9f],translation:[-0.45f,0f,-0.45f]}}/scoreboard players add #tick c9_t 1/execute if score #tick c9_t matches 80.. run scoreboard players set #tick c9_t 0/execute if score #tick c9_t matches 1 run summon minecraft:item ~-4 ~1 ~3 {Tags:["c9_all","c9_debris"],Glowing:1b,PickupDelay:32767,Age:5880,Item:{id:"minecraft:amethyst_shard",count:1}}/execute if score #tick c9_t matches 25 run summon minecraft:item ~4 ~1 ~-2 {Tags:["c9_all","c9_debris"],Glowing:1b,PickupDelay:32767,Age:5880,Item:{id:"minecraft:raw_gold",count:1}}/execute if score #tick c9_t matches 50 run summon minecraft:item ~1 ~1 ~-5 {Tags:["c9_all","c9_debris"],Glowing:1b,PickupDelay:32767,Age:5880,Item:{id:"minecraft:prismarine_crystals",count:1}}/execute as @e[tag=c9_sweep] at @s facing entity @e[tag=c9_debris,limit=1,sort=nearest] feet run tp @s ^ ^ ^0.18 ~ 0/execute as @e[tag=c9_sweep] at @s unless entity @e[tag=c9_debris] facing ~ ~0.1 ~ run tp @s ^0.15 ^ ^ ~10 0/execute as @e[tag=c9_sweep] at @s run particle minecraft:dust{color:[0.1,0.9,1.0],scale:1.0} ~ ~0.1 ~ 0.25 0.02 0.25 0 2/execute at @e[tag=c9_sweep] as @e[tag=c9_debris,distance=..1.1] at @s run particle minecraft:soul_fire_flame ~ ~0.2 ~ 0.15 0.15 0.15 0.05 12/execute at @e[tag=c9_sweep] run kill @e[tag=c9_debris,distance=..1.1]/execute as @e[tag=c9_target] at @s facing ~ ~0.5 ~ run tp @s ^-0.24 ^ ^0.02 ~ 0/execute as @e[tag=c9_turret] at @s facing entity @e[tag=c9_target,limit=1] eyes run tp @s ~ ~ ~ ~ ~/execute as @e[tag=c9_turret] at @s run particle minecraft:dust{color:[1.0,0.1,0.1],scale:1.2} ^ ^ ^1.5 0.05 0.05 0.05 0 2/execute if score #tick c9_t matches 1..20 as @e[tag=c9_turret] at @s run particle minecraft:electric_spark ^ ^ ^3.5 0.8 0.2 0.8 0.02 8setup #6 Summons the central turret head using a scaled and centered <code>block_display</code> observer with a crimson glow override.setup #8 Creates the first autonomous sweeper robot using a flattened <code>sea_lantern</code> block display that glows bright cyan.loop #6 Makes every sweeper drone find the nearest piece of tagged debris, rotate toward it, and glide forward along the floor.loop #9 Triggers a burst of blue soul fire flames whenever a sweeper gets within 1.1 blocks of a debris item before the next command deletes the item.loop #12 Rotates the central observer turret every tick so it stays locked onto the orbiting Intruder Drone.


Recorded on our own test server: 58 frames at about 9.5 fps. Our image check saw: A gray square test pad with a central red turret, three cyan glowing sweeper drones emitting particles, and dropped items on the floor.
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 sentry turret track real players instead of the demo drone, replace @e[tag=c9_target,limit=1] in loop command 12 with @p[distance=..10]. You can also let the sweepers clean up any dropped items by removing tag=c9_debris and filtering by type=item,distance=..10 instead.
/kill @e[tag=c9_all]/scoreboard objectives remove c9_t/fill ~-9 ~-1 ~-9 ~9 ~-1 ~9 minecraft:grass_block/setblock ~ ~ ~ minecraft:airBy default, the sweepers only target items with the c9_debris tag so they don't accidentally delete your gear. Check the player version tip above to let them vacuum any dropped item.
No, debris only spawns three times every 4 seconds, gets deleted immediately by the sweepers, and has a short built-in despawn age of 6 seconds as a backup safety limit.
▶Goliath Watchmaker Tourbillon EscapementFactories & MachinesExpert24 cmds
▶High-Voltage Tesla Coil Plasma Arc SymphonyFactories & MachinesHard24 cmds
▶Industrial Hydraulic Press vs Anvil & DiamondFactories & MachinesMedium24 cmds
▶Kinetic Strandbeest Wind WalkerFactories & MachinesExpert24 cmds
▶Mechanical Hummingbird Nectar Hover RigFactories & MachinesExpert24 cmds
▶Orbital Space Elevator Tether DeploymentFactories & MachinesHard24 cmds