
execute if score el_1 scenes matches 1 run playsound elevator_button master @a ~ ~ ~ 99999
execute if score el_1 scenes matches 1 run scoreboard players set el_button_allow map 0
execute if score el_1 scenes matches 1 as @e[type=item_display,tag=elevator_button,name=1] at @s run data merge entity @s {item:{id:"minecraft:coal",Count:1b,tag:{CustomModelData:72}}}
execute if score el_1 scenes matches 20 as @e[type=item_display,tag=elevator_button,name=1] at @s run data merge entity @s {item:{id:"minecraft:coal",Count:1b,tag:{CustomModelData:71}}}


execute if score el_1 scenes matches 50 run playsound minecraft:elevator_arrive master @a 20 43 -66 1

execute if score el_1 scenes matches 210 run playsound minecraft:elevator_open master @a 18 43 -66 1
execute if score el_1 scenes matches 190 run playsound minecraft:elevator_ring master @a 21 45 -67 1
execute if score el_1 scenes matches 210..230 as @e[tag=1,name=elevator_door_left] at @s run tp @s ~ ~ ~-0.05
execute if score el_1 scenes matches 210..230 as @e[tag=1,name=elevator_door_right] at @s run tp @s ~ ~ ~0.05
execute if score el_1 scenes matches 210 run setblock 20 45 -66 light[level=11]
execute if score el_1 scenes matches 230 run setblock 18 44 -66 minecraft:air
execute if score el_1 scenes matches 200 run execute as @e[tag=1,name=elevator_door_left] at @s run tp @s 18.5 ~ -65.5
execute if score el_1 scenes matches 200 run execute as @e[tag=1,name=elevator_door_right] at @s run tp @s 18.5 ~ -65.5

execute if score el_1 scenes matches 231 if entity @p[x=20,y=43,z=-66,distance=..1] run scoreboard players set el_1 scenes 240
execute if score el_1 scenes matches 240 run scoreboard players set banging_door scenes 0
execute if score el_1 scenes matches 240 run scoreboard players set electric_water ambient 0
execute if score el_1 scenes matches 240 run scoreboard players set ambient map 0
execute if score el_1 scenes matches 240 run scoreboard players set gamemode map 2
execute if score el_1 scenes matches 240 run bossbar set objectives visible false
execute if score el_1 scenes matches 240 run bossbar set obj_detail visible false
execute if score el_1 scenes matches 240 run setblock 18 44 -66 minecraft:oak_fence
execute if score el_1 scenes matches 240 run playsound minecraft:elevator_close master @a 18 43 -66 1
execute if score el_1 scenes matches 240 run playsound minecraft:entity.zombie.break_wooden_door master @a 5 43 -79 1.8 0.8
execute if score el_1 scenes matches 240 run scoreboard players set chase_music map 0
execute if score el_1 scenes matches 240 run playsound minecraft:bgm3_end master @a ~ ~ ~ 99999999999999
execute if score el_1 scenes matches 240..260 as @e[tag=1,name=elevator_door_left] at @s run tp @s ~ ~ ~0.05
execute if score el_1 scenes matches 240..260 as @e[tag=1,name=elevator_door_right] at @s run tp @s ~ ~ ~-0.05
execute if score el_1 scenes matches 260 run execute as @e[tag=1,name=elevator_door_left] at @s run tp @s 18.5 ~ -65.5
execute if score el_1 scenes matches 260 run execute as @e[tag=1,name=elevator_door_right] at @s run tp @s 18.5 ~ -65.5


execute if score el_1 scenes matches 280 run scoreboard players set elevator_ride ambient 1

execute if score el_1 scenes matches 420 at @p run playsound minecraft:elevator_bang master @a ~ ~10 ~ 1
execute if score el_1 scenes matches 460 at @p run playsound minecraft:elevator_stuck master @a ~ ~ ~ 1

execute if score el_1 scenes matches 470 run scoreboard players set elevator_ride ambient 0

execute if score el_1 scenes matches 500 run playsound minecraft:bgm2 master @a ~ ~ ~ 9999999999999
execute if score el_1 scenes matches 545 run playsound minecraft:lights_flicker master @a 19 44 -66 1

execute if score el_1 scenes matches 547 run setblock 20 45 -66 air
execute if score el_1 scenes matches 550 run setblock 20 45 -66 light[level=11]
execute if score el_1 scenes matches 554 run setblock 20 45 -66 air
execute if score el_1 scenes matches 554 run title @a times 0 99999 0
execute if score el_1 scenes matches 554 run title @a title "\uE001"

execute if score el_1 scenes matches 600 at @p run playsound minecraft:elevator_creaking master @a ~ ~ ~ 99999

execute if score el_1 scenes matches 670 run playsound vent master @a 40 25 -64
execute if score el_1 scenes matches 690 run playsound vent master @a 40 25 -64

execute if score el_1 scenes matches 720 run playsound minecraft:lights_flicker master @a 40 25 -64 1
execute if score el_1 scenes matches 720 run execute as @e[name=elevator,tag=falling] at @s run data merge entity @s {item:{id:"minecraft:coal",Count:1b,tag:{CustomModelData:46}}}

execute if score el_1 scenes matches 725 run playsound minecraft:scare1 master @a ~ ~ ~ 999999999
execute if score el_1 scenes matches 730 run title @a times 0 0 0
execute if score el_1 scenes matches 720 run playsound minecraft:lights_flicker master @a 40 25 -64 1
execute if score el_1 scenes matches 730 run setblock 40 25 -64 light[level=11]
execute if score el_1 scenes matches 730 run scoreboard players set mass_rustle map 1

execute if score el_1 scenes matches 660..729 as @p at @s run tp @a 38.99 23 -64.5 -43.5 1
execute if score el_1 scenes matches 710..980 as @p at @s run tp @s 38.99 23 -64.5 ~ ~

execute if score el_1 scenes matches 740 run playsound minecraft:elevator_breaks master @a ~ ~ ~ 999999999
execute if score el_1 scenes matches 760 run scoreboard players set elevator_ride ambient 20

execute if score el_1 scenes matches 720 run playsound minecraft:block.anvil.land master @a 40 25 -64 1 0

execute if score el_1 scenes matches 900 run scoreboard players set elevator_ride ambient 0
execute if score el_1 scenes matches 900 run title @a times 0 99999 0
execute if score el_1 scenes matches 900 run title @a title "\uE001"
execute if score el_1 scenes matches 900 run scoreboard players set mass_rustle map 0
execute if score el_1 scenes matches 900 run stopsound @a master mass2
execute if score el_1 scenes matches 980 run scoreboard players set end map 1

execute if score el_1 scenes matches 820 run playsound minecraft:lights_flicker master @a 40 25 -64 1
execute if score el_1 scenes matches 821 run setblock 40 25 -64 air
execute if score el_1 scenes matches 823 run execute as @e[name=elevator,tag=falling] at @s run data merge entity @s {item:{id:"minecraft:coal",Count:1b,tag:{CustomModelData:80}}}
execute if score el_1 scenes matches 825 run setblock 40 25 -64 light[level=11]


# Lights Flashing

execute if score el_1 scenes matches 760 run playsound minecraft:lights_flicker master @a 40 25 -64 1
execute if score el_1 scenes matches 763 run setblock 40 25 -64 air
execute if score el_1 scenes matches 765 run setblock 40 25 -64 light[level=11]

execute if score el_1 scenes matches 880 run playsound minecraft:lights_flicker master @a 40 25 -64 1
execute if score el_1 scenes matches 883 run setblock 40 25 -64 air
execute if score el_1 scenes matches 885 run setblock 40 25 -64 light[level=11]

execute if score el_1 scenes matches 885 run playsound minecraft:lights_flicker master @a 40 25 -64 1

execute if score el_1 scenes matches 890 run playsound minecraft:lights_flicker master @a 40 25 -64 1
execute if score el_1 scenes matches 893 run setblock 40 25 -64 air
execute if score el_1 scenes matches 895 run setblock 40 25 -64 light[level=11]
execute if score el_1 scenes matches 897 run setblock 40 25 -64 air


execute if score el_1 scenes matches 1..230 run scoreboard players add el_1 scenes 1
execute if score el_1 scenes matches 240..980 run scoreboard players add el_1 scenes 1




