execute @s[tag=dev] ~~~ event entity @e[family=conveyor] xp:instant_despawn
execute @s[tag=dev] ~~~ event entity @e[type=xp:waypoint] xp:instant_despawn
execute @s[tag=dev] ~~~ event entity @e[family=tutorial_chicken] xp:instant_despawn
execute @s[tag=dev] ~~~ event entity @e[type=xp:tutorial_scientist] xp:instant_despawn

execute @s[tag=dev] ~~~ summon xp:conveyor 84 54.92 187
execute @s[tag=dev] ~~~ summon xp:tutorial_scientist 82 55 189

execute @s[tag=dev] ~~~ structure load mystructure:clamp_5 69 56 174
execute @s[tag=dev] ~~~ structure load mystructure:clamp_5 48 56 174
execute @s[tag=dev] ~~~ structure load mystructure:clamp_5 27 56 174

execute @s[tag=dev] ~~~ setblock 48 58 187 redstone_lamp
execute @s[tag=dev] ~~~ setblock 47 58 187 lever 2
execute @s[tag=dev] ~~~ tag @e[type=xp:door,x=18,y=57,z=187,r=4] add unopenable

execute @s[tag=dev] ~~~ tag @a remove dialogue_1
execute @s[tag=dev] ~~~ tag @a remove dialogue_2
execute @s[tag=dev] ~~~ tag @a remove dialogue_3
execute @s[tag=dev] ~~~ tag @a remove dialogue_4
execute @s[tag=dev] ~~~ tag @a remove dialogue_5
execute @s[tag=dev] ~~~ tag @a remove dialogue_6
execute @s[tag=dev] ~~~ tag @a remove dialogue_7
execute @s[tag=dev] ~~~ tag @a remove dialogue_8
execute @s[tag=dev] ~~~ tag @a remove dialogue_9
execute @s[tag=dev] ~~~ tag @a remove dialogue_10
execute @s[tag=dev] ~~~ tag @a remove dialogue_11
execute @s[tag=dev] ~~~ tag @a remove dialogue_12
execute @s[tag=dev] ~~~ tag @a remove dialogue_13
execute @s[tag=dev] ~~~ tag @a remove dialogue_14
execute @s[tag=dev] ~~~ tag @a remove dialogue_15
execute @s[tag=dev] ~~~ tag @a remove dialogue_16
execute @s[tag=dev] ~~~ tag @a remove dialogue_17
execute @s[tag=dev] ~~~ tag @a remove dialogue_18
execute @s[tag=dev] ~~~ tag @a remove tutorial_finished

execute @s[tag=dev] ~~~ tag @a add in_tutorial
execute @s[tag=dev] ~~~ tag @a remove in_conveyor
execute @s[tag=dev] ~~~ tp @a 103 57 187 facing @e[type=xp:door,c=1]
execute @s[tag=dev] ~~~ clear @a xp:morphifier

execute @s[tag=!dev] ~~~ gamerule sendcommandfeedback false
execute @s[tag=dev] ~~~ gamerule sendcommandfeedback true
execute @s[tag=!dev] ~~~ tellraw @s {"rawtext":[{"text":"§c"},{"translate":"commands.generic.unknown","with":{"rawtext":[{"text":"function tutorial/setup"}]}}]}