Scurrying Animated Critter

Watch a custom multi-part Scarab Beetle scurry across a crystal garden with a smooth procedural walk cycle, obstacle avoidance, and glowing particle trails.

Java EditionMobs & PetsMedium25 commandsTested on a real 26.2 & 26.3 server
A glowing miniature golden scarab beetle crawls between purple amethyst blocks on a grassy lawn at night. Download the GIF Video & GIF © www.9minecraft.net

Pets & CompanionsNatureCuteMysticGoldGreenPurpleDecorationAdventure MapLearningBlock displaysSmooth animation (interpolation)Block building (fill/setblock/clone)Rotation math21+ commands

Traditional Minecraft mobs are limited to the shapes built into the game, unless you use display entities to construct your own creatures from scratch. This creation builds a miniature Scarab Beetle out of gold, emerald, and sea lantern block displays, complete with six articulated legs that swing back and forth in an alternating tripod walk cycle as it explores a crystal obstacle garden.

The beetle moves autonomously using a marker brain that checks the blocks directly ahead of it every tick. Whenever it bumps into one of the glowing amethyst pillars or wanders too far from the stage center, it emits a burst of magic particles and smoothly steers onto a new path while its golden shell bobs up and down.

1. Setup - type these once 11 commands

  1. /scoreboard objectives add c9_tick dummy
  2. /fill ~-6 ~ ~-6 ~6 ~1 ~6 air
  3. /setblock ~3 ~ ~2 amethyst_block
  4. /setblock ~-3 ~ ~1 amethyst_block
  5. /setblock ~1 ~ ~-3 amethyst_block
  6. /setblock ~-2 ~ ~-2 amethyst_block
  7. /summon marker ~ ~ ~ {Tags:["c9_ent","c9_bug"],Rotation:[35f,0f]}
  8. /summon block_display ~ ~ ~ {Tags:["c9_ent","c9_body"],Glowing:1b,glow_color_override:65450,teleport_duration:1,interpolation_duration:2,block_state:{Name:"minecraft:gold_block"},transformation:{translation:[-0.25f,0.18f,-0.35f],scale:[0.5f,0.3f,0.7f],left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f]}}
  9. /summon block_display ~ ~ ~ {Tags:["c9_ent","c9_head"],Glowing:1b,glow_color_override:16766720,teleport_duration:1,block_state:{Name:"minecraft:sea_lantern"},transformation:{translation:[-0.2f,0.22f,0.25f],scale:[0.4f,0.22f,0.25f],left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f]}}
  10. /summon block_display ~ ~ ~ {Tags:["c9_ent","c9_leg1"],Glowing:1b,glow_color_override:65450,teleport_duration:1,interpolation_duration:2,block_state:{Name:"minecraft:emerald_block"},transformation:{translation:[-0.5f,0.12f,-0.08f],scale:[1.0f,0.12f,0.16f],left_rotation:[0f,0.18f,0f,0.98f],right_rotation:[0f,0f,0f,1f]}}
  11. /summon block_display ~ ~ ~ {Tags:["c9_ent","c9_leg2"],Glowing:1b,glow_color_override:65450,teleport_duration:1,interpolation_duration:2,block_state:{Name:"minecraft:emerald_block"},transformation:{translation:[-0.5f,0.12f,-0.08f],scale:[1.0f,0.12f,0.16f],left_rotation:[0f,-0.18f,0f,0.98f],right_rotation:[0f,0f,0f,1f]}}

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

  1. /scoreboard players add #t c9_tick 1
  2. /execute if score #t c9_tick matches 8.. run scoreboard players set #t c9_tick 0
  3. /execute as @e[tag=c9_bug] at @s unless block ^ ^ ^0.75 air run tp @s ~ ~ ~ ~115 0
  4. /execute as @e[tag=c9_bug] at @s unless block ^ ^ ^0.75 air run particle wax_on ~ ~0.3 ~ 0.25 0.2 0.25 0 8
  5. /execute as @e[tag=c9_bug,distance=5.5..] at @s facing ~ ~ ~ run tp @s ~ ~ ~ ~15 0
  6. /execute as @e[tag=c9_bug] at @s if block ^ ^ ^0.75 air run tp @s ^ ^ ^0.14 ~3 0
  7. /execute at @e[tag=c9_bug] as @e[tag=c9_ent,tag=!c9_bug] run tp @s ~ ~ ~ ~ ~
  8. /execute if score #t c9_tick matches 0 as @e[tag=c9_leg1] run data merge entity @s {start_interpolation:0,interpolation_duration:4,transformation:{translation:[-0.5f,0.12f,-0.08f],scale:[1.0f,0.12f,0.16f],left_rotation:[0f,0.28f,0f,0.96f],right_rotation:[0f,0f,0f,1f]}}
  9. /execute if score #t c9_tick matches 4 as @e[tag=c9_leg1] run data merge entity @s {start_interpolation:0,interpolation_duration:4,transformation:{translation:[-0.5f,0.12f,-0.08f],scale:[1.0f,0.12f,0.16f],left_rotation:[0f,-0.28f,0f,0.96f],right_rotation:[0f,0f,0f,1f]}}
  10. /execute if score #t c9_tick matches 0 as @e[tag=c9_leg2] run data merge entity @s {start_interpolation:0,interpolation_duration:4,transformation:{translation:[-0.5f,0.12f,-0.08f],scale:[1.0f,0.12f,0.16f],left_rotation:[0f,-0.28f,0f,0.96f],right_rotation:[0f,0f,0f,1f]}}
  11. /execute if score #t c9_tick matches 4 as @e[tag=c9_leg2] run data merge entity @s {start_interpolation:0,interpolation_duration:4,transformation:{translation:[-0.5f,0.12f,-0.08f],scale:[1.0f,0.12f,0.16f],left_rotation:[0f,0.28f,0f,0.96f],right_rotation:[0f,0f,0f,1f]}}
  12. /execute if score #t c9_tick matches 0 as @e[tag=c9_body] run data merge entity @s {start_interpolation:0,interpolation_duration:4,transformation:{translation:[-0.25f,0.23f,-0.35f],scale:[0.5f,0.3f,0.7f],left_rotation:[0f,0f,0.06f,0.998f],right_rotation:[0f,0f,0f,1f]}}
  13. /execute if score #t c9_tick matches 4 as @e[tag=c9_body] run data merge entity @s {start_interpolation:0,interpolation_duration:4,transformation:{translation:[-0.25f,0.17f,-0.35f],scale:[0.5f,0.3f,0.7f],left_rotation:[0f,0f,-0.06f,0.998f],right_rotation:[0f,0f,0f,1f]}}
  14. /execute at @e[tag=c9_bug] run particle dust{color:[0.2,1.0,0.6],scale:0.7} ~ ~0.15 ~ 0.15 0.05 0.15 0 2

How it works

Frames from the test run

Scurrying Animated Critter - frame 1Scurrying Animated Critter - frame 2Scurrying Animated Critter - frame 3

Recorded on our own test server: 59 frames at about 9.8 fps. Our image check saw: A small glowing golden beetle with green legs scurries across the grass between purple amethyst blocks before walking off-screen.

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 center of a flat open area and run the setup commands in order to create the scoreboard objective, place the four amethyst obstacle blocks, and summon the beetle parts.
  2. Place a column or line of 14 repeating command blocks set to Always Active near your stage.
  3. Paste one loop command into each repeating command block.
  4. Watch the golden scarab immediately begin scurrying in gentle arcs around the amethyst blocks, turning with a burst of sparkles whenever it senses a block ahead.
  5. Try placing extra blocks directly in front of the beetle while it walks to test its obstacle sensor in real time.

Use it with real players

To turn the critter into a companion pet that follows you instead of wandering inside the garden, replace loop command 5 (the distance=5.5.. boundary check) with /execute as @e[tag=c9_bug] at @s if entity @p[distance=3..] facing entity @p feet run tp @s ~ ~ ~ ~ ~ so it steers toward the nearest player whenever you walk away.

Remove it again 3 commands

  1. /kill @e[tag=c9_ent]
  2. /fill ~-6 ~ ~-6 ~6 ~1 ~6 air
  3. /scoreboard objectives remove c9_tick

FAQ

Why does the beetle glide smoothly instead of snapping each tick?

Each block_display has teleport_duration set to 1 for smooth movement and interpolation_duration set to 4 for its transformation matrix, so the client blends the leg rotations between keyframes.

Can I change how fast the critter walks?

Yes. Increase or decrease the ^ ^ ^0.14 step distance in the sixth loop command to change its speed, and adjust the 8-tick cycle reset in the second loop command to match.

Commands used

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

Similar creations

Join 9Minecraft News & Guides