Grand Hinged Castle Gate & Drawbridge

Build a medieval castle gatehouse over a water moat with a heavy oak drawbridge that smoothly swings down on its hinge and a rising iron portcullis.

Java EditionHolograms & Display EntitiesMedium24 commandsTested on a real 26.2 & 26.3 server
A wooden drawbridge lowers over a moat as an iron portcullis rises into a stone castle gatehouse. Download the GIF Video & GIF © www.9minecraft.net

Animated BlocksMedievalRoyalOrangeBlueWhiteAdventure MapMap MakingDecorationBlock displaysSmooth animation (interpolation)Block building (fill/setblock/clone)Sounds21+ commands

Traditional redstone piston doors are bulky and move in rigid one-block steps. By combining block_display entities with transformation matrices and smooth interpolation, this command creation builds a stone castle gatehouse over a wide moat where a large wooden drawbridge smoothly rotates 90 degrees downward on its bottom hinge while an iron portcullis slides open.

As the bridge drops across the water, heavy chain winches smoke and spark at the top of the archway, and the bridge slams down over the water with a big splash and dust cloud before raising back up to seal the fortress.

1. Setup - type these once 10 commands

  1. /scoreboard objectives add c9_t dummy
  2. /fill ~-6 ~-1 ~-2 ~6 ~-1 ~7 water
  3. /fill ~-6 ~ ~-2 ~6 ~9 ~1 stone_bricks
  4. /fill ~-2 ~ ~-2 ~2 ~5 ~1 air
  5. /fill ~-6 ~10 ~-2 ~6 ~10 ~1 chiseled_stone_bricks
  6. /fill ~-3 ~-1 ~-3 ~3 ~-1 ~8 cobblestone
  7. /fill ~-3 ~-1 ~2 ~3 ~-1 ~6 water
  8. /summon marker ~ ~ ~ {Tags:["c9_ent","c9_ctrl"]}
  9. /summon block_display ~ ~ ~1.1 {Tags:["c9_ent","c9_bridge"],Glowing:1b,glow_color_override:16755200,interpolation_duration:45,block_state:{Name:"minecraft:spruce_planks"},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-2.5f,0f,-0.2f],scale:[5f,6f,0.4f]}}
  10. /summon block_display ~ ~ ~-0.5 {Tags:["c9_ent","c9_port"],Glowing:1b,glow_color_override:11184810,interpolation_duration:45,block_state:{Name:"minecraft:iron_bars",Properties:{east:"true",west:"true"}},transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-2.5f,0f,0f],scale:[5f,6f,0.2f]}}

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

  1. /scoreboard players add @e[tag=c9_ctrl] c9_t 1
  2. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 140.. run scoreboard players set @e[tag=c9_ctrl] c9_t 1
  3. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 5 run data merge entity @e[tag=c9_bridge,limit=1] {start_interpolation:0,interpolation_duration:45,transformation:{left_rotation:[0.7071f,0f,0f,0.7071f],right_rotation:[0f,0f,0f,1f],translation:[-2.5f,0f,-0.2f],scale:[5f,6f,0.4f]}}
  4. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 5 run data merge entity @e[tag=c9_port,limit=1] {start_interpolation:0,interpolation_duration:45,transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-2.5f,4.8f,0f],scale:[5f,6f,0.2f]}}
  5. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 75 run data merge entity @e[tag=c9_bridge,limit=1] {start_interpolation:0,interpolation_duration:45,transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-2.5f,0f,-0.2f],scale:[5f,6f,0.4f]}}
  6. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 75 run data merge entity @e[tag=c9_port,limit=1] {start_interpolation:0,interpolation_duration:45,transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-2.5f,0f,0f],scale:[5f,6f,0.2f]}}
  7. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 5..50 run particle flame ~-2.3 ~5.5 ~1.3 0.1 0.1 0.1 0.03 3
  8. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 5..50 run particle flame ~2.3 ~5.5 ~1.3 0.1 0.1 0.1 0.03 3
  9. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 75..120 run particle crit ~-2.3 ~5.5 ~1.3 0.2 0.2 0.2 0.15 5
  10. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 75..120 run particle crit ~2.3 ~5.5 ~1.3 0.2 0.2 0.2 0.15 5
  11. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 50 run particle splash ~ ~0.2 ~4.0 2.0 0.2 2.0 0.3 120
  12. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 50 run particle cloud ~ ~0.3 ~6.5 1.8 0.2 0.5 0.05 35
  13. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 50 run playsound minecraft:entity.zombie.break_wooden_door master @a ~ ~ ~ 1.0 0.6
  14. /execute if score @e[tag=c9_ctrl,limit=1] c9_t matches 120 run playsound minecraft:block.anvil.place master @a ~ ~ ~ 0.9 0.7

How it works

Frames from the test run

Grand Hinged Castle Gate & Drawbridge - frame 1Grand Hinged Castle Gate & Drawbridge - frame 2Grand Hinged Castle Gate & Drawbridge - frame 3

Recorded on our own test server: 67 frames at about 9.4 fps. Our image check saw: A wooden drawbridge smoothly rotates down across a water moat from a stone brick wall while an iron portcullis slides upward.

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 build area facing north or south where you want the castle gatehouse to appear.
  2. Run the 10 setup commands in order in chat or a one-time impulse command block line to build the moat, stone brick gatehouse, and display entities.
  3. Place a column or chain of 14 repeating command blocks (or 1 repeating and 13 chain command blocks) set to Always Active.
  4. Paste each loop command into the command blocks so they execute at the same center coordinate.
  5. Watch the drawbridge automatically swing down over the water moat and raise back up on a 7-second cycle.

Use it with real players

To let players control the drawbridge with a lever instead of running on an automatic loop, remove the c9_t timer reset and split the loop into two impulse command block chains wired to a lever: trigger the tick 5 data merge commands when the lever turns on to lower the bridge, and trigger the tick 75 data merge commands when the lever turns off to raise it back up. If you want players to actually walk across the lowered display bridge, add /fill ~-2 ~-1 ~2 ~2 ~-1 ~6 barrier when the bridge hits tick 50 and replace the barriers with water when raising begins at tick 75.

Remove it again 4 commands

  1. /kill @e[tag=c9_ent]
  2. /scoreboard objectives remove c9_t
  3. /fill ~-6 ~ ~-3 ~6 ~10 ~8 air
  4. /fill ~-6 ~-1 ~-3 ~6 ~-1 ~8 grass_block

FAQ

Why does the drawbridge pivot around its bottom edge instead of spinning in its center?

A block_display rotates around its entity origin. Because the entity is summoned at the bottom floor level (~ ~ ~1.1) and its translation leaves Y at 0 while scaling Y to 6, the entire 6-block tall bridge extends upward from the pivot point and swings down like a real hinge when left_rotation is applied.

Can players walk on the block_display drawbridge without falling into the water?

Display entities are purely visual and do not have collision boxes of their own. To walk across, either place invisible barrier blocks at water level when the bridge finishes lowering or summon shulkers riding markers along the bridge span.

Commands used

/data/execute/fill/particle/playsound/scoreboard/summon

Similar creations

Join 9Minecraft News & Guides