execute if block 7 75 45 stone_button[powered=true] run scoreboard players set @e[tag=tutStand] tutorial 601
execute if block 7 75 45 stone_button[powered=true] run setblock 7 75 45 stone_button[powered=false,face=floor,facing=north]

scoreboard players remove @e[tag=tutStand,scores={tutorial=1..}] tutorial 1
execute if score @e[tag=tutStand,limit=1] tutorial matches 600 run fill 24 60 -18 -25 51 -67 air
execute if score @e[tag=tutStand,limit=1] tutorial matches 600 run fill 24 50 -18 -25 50 -67 dirt
execute if score @e[tag=tutStand,limit=1] tutorial matches 1..600 run gamemode spectator @a[y=3]
execute if score @e[tag=tutStand,limit=1] tutorial matches 600 run tellraw @a[y=3] {"text":"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n "}

execute if score @e[tag=tutStand,limit=1] tutorial matches 480..600 run tp @a[y=3] 0.0 76.0 -42.0 0 90
execute if score @e[tag=tutStand,limit=1] tutorial matches 600 run tellraw @a[y=3] ["",{"text":"Welcome to "},{"bold":true,"color":"light_purple","text":"PARKOUR PANIC!"}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 560 run tellraw @a[y=3] ["",{"text":"When the game begins... a map will be "},{"bold":true,"color":"green","text":"randomly generated"},{"text":" for you to play on!\n"}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 550 run clone 24 32 -18 -25 42 -67 -25 50 -67

execute if score @e[tag=tutStand,limit=1] tutorial matches 440..480 run tp @a[y=3] 4.0 58.5 -55.0 -143.8 34.3
execute if score @e[tag=tutStand,limit=1] tutorial matches 470..470 run tellraw @a[y=3] ["",{"text":"As will a "},{"bold":true,"color":"red","text":"start..."}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 460..460 run clone 35 32 -29 26 42 -38 5 50 -67

execute if score @e[tag=tutStand,limit=1] tutorial matches 360..440 run tp @a[y=3] -15.5 57.0 -25.5 -139.1 21.3
execute if score @e[tag=tutStand,limit=1] tutorial matches 430..430 run tellraw @a[y=3] ["",{"text":"And an "},{"bold":true,"color":"gold","text":"end point"},{"text":", as designated by "},{"bold":true,"color":"yellow","text":"yellow beacons"},{"text":"."}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 420..420 run clone 35 32 -18 26 45 -27 -15 50 -37
execute if score @e[tag=tutStand,limit=1] tutorial matches 390..390 run tellraw @a[y=3] ["",{"text":"There will also be a "},{"bold":true,"color":"light_purple","text":"GPS (compass)"},{"text":" in your hotbar, that points to the "},{"bold":true,"color":"gold","text":"end point"},{"text":".\n"}]

execute if score @e[tag=tutStand,limit=1] tutorial matches 240..360 run tp @a[y=3] 12.7 57.5 -51.037 111.3 23.5
execute if score @e[tag=tutStand,limit=1] tutorial matches 340..340 run summon armor_stand 7.5 52.2 -54.25 {NoGravity:1b,ShowArms:1b,NoBasePlate:1b,Tags:["tut360"],Pose:{LeftArm:[207f,335f,0f],RightArm:[219f,20f,0f],LeftLeg:[20f,20f,349f],RightLeg:[13f,349f,13f],Head:[337f,0f,0f]},equipment:{feet:{id:"minecraft:leather_boots",count:1,components:{"minecraft:dyed_color":16746496}},legs:{id:"minecraft:leather_leggings",count:1,components:{"minecraft:dyed_color":0}},chest:{id:"minecraft:leather_chestplate",count:1,components:{"minecraft:dyed_color":16746496}},head:{components:{"minecraft:profile":{name:"RemoteBirch5"}},count:1,id:"minecraft:player_head"}}}
execute if score @e[tag=tutStand,limit=1] tutorial matches 340..340 run summon armor_stand 6.546 54.0 -58.336 {NoGravity:1b,ShowArms:1b,NoBasePlate:1b,Tags:["tut360"],Pose:{LeftArm:[16f,0f,327f],RightArm:[258f,78f,0f],LeftLeg:[327f,335f,0f],RightLeg:[16f,344f,0f],Head:[346f,344f,0f]},Rotation:[339F,NaNF],equipment:{feet:{id:"minecraft:leather_boots",count:1,components:{"minecraft:dyed_color":0}},legs:{id:"minecraft:leather_leggings",count:1,components:{"minecraft:dyed_color":5634763}},chest:{id:"minecraft:leather_chestplate",count:1,components:{"minecraft:dyed_color":8060898}},head:{id:"minecraft:player_head",count:1,components:{"minecraft:profile":{name:"3FromTheBack"}}}}}
execute if score @e[tag=tutStand,limit=1] tutorial matches 340..340 run summon armor_stand 10.6 53.0 -56.6 {NoGravity:1b,ShowArms:1b,NoBasePlate:1b,Tags:["tut360"],Pose:{LeftArm:[326f,5f,0f],RightArm:[18f,0f,14f],LeftLeg:[31f,0f,0f],RightLeg:[338f,0f,0f],Head:[349f,348f,0f]},equipment:{feet:{components:{"minecraft:dyed_color":16652316},count:1,id:"minecraft:leather_boots"},legs:{components:{"minecraft:dyed_color":4761847},count:1,id:"minecraft:leather_leggings"},chest:{components:{"minecraft:dyed_color":4761847},count:1,id:"minecraft:leather_chestplate"},head:{components:{"minecraft:profile":{name:"CDwg"}},count:1,id:"minecraft:player_head"}}}
execute if score @e[tag=tutStand,limit=1] tutorial matches 320..320 run tellraw @a[y=3] ["",{"text":"Players will all be teleported to the "},{"bold":true,"color":"red","text":"start..."}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 280..280 run tellraw @a[y=3] ["",{"text":"After a "},{"bold":true,"color":"dark_purple","text":"countdown"},{"text":", everyone will race to the "},{"bold":true,"color":"gold","text":"end"},{"text":" of the course!\n"}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 240..240 run kill @e[tag=tut360]

execute if score @e[tag=tutStand,limit=1] tutorial matches 120..240 run tp @a[y=3] -13.7 56.3 -33.7 -107.9 22.6
execute if score @e[tag=tutStand,limit=1] tutorial matches 220..220 run summon armor_stand -9.6 57.5 -38.882 {NoGravity:1b,ShowArms:1b,NoBasePlate:1b,Tags:["tut240"],Pose:{LeftArm:[249f,294f,0f],RightArm:[144f,0f,318f],LeftLeg:[20f,20f,349f],RightLeg:[13f,349f,13f],Head:[27f,0f,0f]},equipment:{feet:{id:"minecraft:leather_boots",count:1,components:{"minecraft:dyed_color":16746496}},legs:{id:"minecraft:leather_leggings",count:1,components:{"minecraft:dyed_color":0}},chest:{id:"minecraft:leather_chestplate",count:1,components:{"minecraft:dyed_color":16746496}},head:{components:{"minecraft:profile":{name:"RemoteBirch5"}},count:1,id:"minecraft:player_head"}}}
execute if score @e[tag=tutStand,limit=1] tutorial matches 220..220 run summon armor_stand -9.472 55 -35.602 {NoGravity:1b,ShowArms:1b,NoBasePlate:1b,Tags:["tut240"],Pose:{LeftArm:[289f,0f,355f],RightArm:[27f,0f,13f],LeftLeg:[327f,335f,0f],RightLeg:[16f,344f,0f],Head:[342f,344f,0f]},Rotation:[34F,NaNF],equipment:{feet:{id:"minecraft:leather_boots",count:1,components:{"minecraft:dyed_color":0}},legs:{id:"minecraft:leather_leggings",count:1,components:{"minecraft:dyed_color":5634763}},chest:{id:"minecraft:leather_chestplate",count:1,components:{"minecraft:dyed_color":8060898}},head:{components:{"minecraft:profile":{name:"3FromTheBack"}},count:1,id:"minecraft:player_head"}}}
execute if score @e[tag=tutStand,limit=1] tutorial matches 220..220 run summon armor_stand -11.094 56.06250 -32.776 {NoGravity:1b,ShowArms:1b,NoBasePlate:1b,Tags:["tut240"],Pose:{LeftArm:[163f,0f,22f],RightArm:[181f,0f,324f],LeftLeg:[9f,0f,351f],RightLeg:[353f,0f,18f],Head:[349f,348f,0f]},Rotation:[172F,NaNF],equipment:{feet:{id:"minecraft:leather_boots",count:1,components:{"minecraft:dyed_color":16652316}},legs:{id:"minecraft:leather_leggings",count:1,components:{"minecraft:dyed_color":4761847}},chest:{id:"minecraft:leather_chestplate",count:1,components:{"minecraft:dyed_color":4761847}},head:{components:{"minecraft:profile":{name:"CDwg"}},count:1,id:"minecraft:player_head"}}}
execute if score @e[tag=tutStand,limit=1] tutorial matches 200..200 run tellraw @a[y=3] ["",{"text":"Traverse the map and get to the "},{"bold":true,"color":"gold","text":"end "},{"color":"white","text":"as fast as you can!"}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 160..160 run tellraw @a[y=3] ["",{"text":"But make sure you aren't "},{"bold":true,"color":"red","text":"last"},{"text":"! Whoever is the slowest will lose a "},{"bold":true,"color":"blue","text":"life"},{"text":".\n"}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 120..120 run kill @e[tag=tut240]

execute if score @e[tag=tutStand,limit=1] tutorial matches 2..120 run tp @a[y=3] -3.465 56.636 -35.307 71.8 17.8
execute if score @e[tag=tutStand,limit=1] tutorial matches 100..100 run tellraw @a ["",{"text":"After a round ends, the previous "},{"bold":true,"color":"gold","text":"end point"},{"color":"white","text":" will become the next rounds "},{"bold":true,"color":"red","text":"start "},{"color":"white","text":"point."}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 80..80 run clone 35 32 -29 26 42 -38 -15 50 -37
execute if score @e[tag=tutStand,limit=1] tutorial matches 60..60 run tellraw @a ["",{"text":"This will continue until only 1 person remains! And they will be crowned the "},{"bold":true,"color":"yellow","text":"winner!"}]
execute if score @e[tag=tutStand,limit=1] tutorial matches 40..40 run tellraw @a ["",{"text":"That's just about everything! We hope you enjoy "},{"bold":true,"color":"light_purple","text":"PARKOUR PANIC!\n"}]

execute if score @e[tag=tutStand,limit=1] tutorial matches 1..1 run gamemode adventure @a[y=3]
execute if score @e[tag=tutStand,limit=1] tutorial matches 1..1 run tp @a[y=3] 1.0 75 52.0