387: Animated lockable door. [Minecraft Map Making]

Subscribers:
3,670
Published on ● Video Link: https://www.youtube.com/watch?v=G6aR9fPDMB4



Minecraft
Game:
Minecraft (2011)
Duration: 1:09:39
389 views
22


Membership:    / @infernaldevice  
Ep387: Nice animated doors that can easily be locked when open or closed just by adding a tag to it.

00:00 Intro
03:00 Create right door
12:55 Test open
21:00 Test close
23:00 Controller
42:40 Rotate

Version: 1.21

Request by: Schadow

GalSergey's Datapack: https://modrinth.com/datapack/door_lo...

Commands, builds and ideas for people making their own Minecraft maps.

Check out my collabs on Coppit's channel:    / coppitj  

Join the CoppitCraft server that I play on and the Discord where I hang out.
Server IP: 51.81.246.145:25588
Discord:   / discord  

Commands used:

Setup:
IUN: scoreboard objectives add state dummy

Create right door:
IUN: summon interaction 10052 56 10079 {Tags:["door", "door_input", "right"], width:1.01, height:2.01, Passengers:[{id:"block_display", Tags:["door","lower", "right"], start_interpolation:0, interpolation_duration:10, block_state:{Name:"spruce_door", Properties:{facing:"south", hinge:"right", half:"lower"}}, transformation:{left_rotation:[0f,0f,0f,1f], right_rotation:[0f,0f,0f,1f], scale:[1f,1f,1f], translation:[-0.5f,0f,-0.5f]}}, {id:"block_display", Tags:["door","upper", "right"], start_interpolation:0, interpolation_duration:10, block_state:{Name:"spruce_door", Properties:{facing:"south", hinge:"right", half:"upper"}}, transformation:{left_rotation:[0f,0f,0f,1f], right_rotation:[0f,0f,0f,1f], scale:[1f,1f,1f], translation:[-0.5f,1f,-0.5f]}}]}
CUA: fill 10052 56 10079 10052 57 10079 barrier

Controller:
RUA: execute as @e[type=interaction, tag=door] at @s store success entity @s interaction.player[] int 0 on target as @e[type=interaction, tag=door,distance=..0.1] run tag @s add active
CUA: execute as @e[type=interaction, tag=!locked, tag=active] store success score @s state if score @s state matches 0
CUA: execute as @e[type=interaction, tag=!locked, tag=active, tag=right, scores={state=0}] at @s run data merge entity @e[type=block_display, tag=lower, limit=1, distance=..0.1] {transformation:{left_rotation:[0.0f,-0.70710677f, 0f,0.70710677f], translation:[-0.3125f,0f,-0.5f]}, start_interpolation:0}
CUA: execute as @e[type=interaction, tag=!locked, tag=active, tag=right, scores={state=0}] at @s run data merge entity @e[type=block_display, tag=upper, limit=1, distance=..0.1] {transformation:{left_rotation:[0.0f,-0.70710677f, 0f,0.70710677f], translation:[-0.3125f,1f,-0.5f]}, start_interpolation:0}
CUA: execute as @e[type=interaction, tag=!locked, tag=active, tag=left, scores={state=0}] at @s run data merge entity @e[type=block_display, tag=lower, limit=1, distance=..0.1] {transformation:{left_rotation:[0.0f,0.70710677f, 0f,0.70710677f], translation:[0.5f,0f,-0.5f], scale:[-1f,1f,-1f]}, start_interpolation:0}
CUA: execute as @e[type=interaction, tag=!locked, tag=active, tag=left, scores={state=0}] at @s run data merge entity @e[type=block_display, tag=upper, limit=1, distance=..0.1] {transformation:{left_rotation:[0.0f,0.70710677f, 0f,0.70710677f], translation:[0.5f,1f,-0.5f], scale:[-1f,1f,-1f]}, start_interpolation:0}
CUA: execute at @e[type=interaction, tag=!locked, tag=active, scores={state=0}] run playsound block.wooden_door.open block @a ~ ~ ~ 1 1 0
CUA: execute as @e[type=interaction, tag=!locked, tag=active, scores={state=0}] at @s run fill ~ ~ ~ ~ ~1 ~ air replace barrier
CUA: execute as @e[type=interaction, tag=!locked, tag=active, tag=right, scores={state=1}] at @s run data merge entity @e[type=block_display, tag=lower, limit=1, distance=..0.1] {transformation:{left_rotation:[0f,0f,0f,1f], translation:[-0.5f,0f,-0.5f]}, start_interpolation:0}
CUA: execute as @e[type=interaction, tag=!locked, tag=active, tag=right, scores={state=1}] at @s run data merge entity @e[type=block_display, tag=upper, limit=1, distance=..0.1] {transformation:{left_rotation:[0f,0f,0f,1f], translation:[-0.5f,1f,-0.5f]}, start_interpolation:0}
CUA: execute as @e[type=interaction, tag=!locked, tag=active, tag=left, scores={state=1}] at @s run data merge entity @e[type=block_display, tag=lower, limit=1, distance=..0.1] {transformation:{left_rotation:[0f,0f,0f,1f], translation:[0.5f,0f,-0.3125f], scale:[-1f,1f,-1f]}, start_interpolation:0}
CUA: execute as @e[type=interaction, tag=!locked, tag=active, tag=left, scores={state=1}] at @s run data merge entity @e[type=block_display, tag=upper, limit=1, distance=..0.1] {transformation:{left_rotation:[0f,0f,0f,1f], translation:[0.5f,1f,-0.3125f], scale:[-1f,1f,-1f]}, start_interpolation:0}
CUA: execute at @e[type=interaction, tag=!locked, tag=active, scores={state=1}] run playsound block.wooden_door.close block @a ~ ~ ~ 1 1 0
CUA: execute as @e[type=interaction, tag=!locked, tag=active, scores={state=1}] at @s run fill ~ ~ ~ ~ ~1 ~ barrier replace air
CUA: execute at @e[type=interaction, tag=locked, tag=active] run playsound entity.zombie.attack_wooden_door master @a ~ ~ ~ 0.2 1 0
CUA: tag @e[type=interaction, tag=active] remove active







Tags:
minecraft
adventure map
map making
commands
command blocks
1.18
custom commands
redstone
map ideas
map suggesstions
custom maps
1.19



Other Statistics

Minecraft Statistics For Infernal Device

At present, Infernal Device has 182,018 views spread across 862 videos for Minecraft, accounting for over 10 days of watchable video on his channel. This is 94.82% of the total watchable video for Minecraft on Infernal Device's YouTube channel.