scoreboard players enable @a[tag=player,scores={player=1..}] free_cam
execute as @a[scores={free_cam=1..}] unless entity @s[tag=free_cam] at @s run function system:event/free_cam/activate
execute as @a[scores={free_cam=1..}] if entity @s[tag=free_cam] at @s run function system:event/free_cam/deactivate
scoreboard players reset @a[scores={free_cam=1..}] free_cam
execute as @a[tag=free_cam,gamemode=!spectator] run function system:event/free_cam/deactivate
effect give @a[scores={checkpoint=6}] resistance infinite 255 true
execute if entity @e[tag=lvl3b] run scoreboard players enable @a[scores={checkpoint=2}] noob_mode
execute as @a[scores={noob_mode=1..}] unless entity @s[tag=noob_mode] at @s run function system:event/noob_mode/activate
execute as @a[scores={noob_mode=1..}] if entity @s[tag=noob_mode] at @s run function system:event/noob_mode/deactivate
scoreboard players reset @a[scores={noob_mode=1..}] noob_mode
execute as @a[gamemode=!spectator] at @s if block ~ ~-1 ~ emerald_block if block ~ ~ ~ cave_air run function system:event/item/give_player
#Kill
execute as @a[gamemode=!spectator] at @s if block ~ ~-1 ~ minecraft:red_wool run function system:event/death/failed {"reason":" hat getestet, ob es ein Geländer gibt und einen Tod vor Beginn der Map erhalten!"}
execute as @a[gamemode=!spectator] at @s if block ~ ~-1 ~ minecraft:blue_ice run function system:event/death/failed {"reason":"-"}
execute as @a[gamemode=!spectator] at @s if block ~ ~-1 ~ minecraft:bedrock run function system:event/death/failed {"reason":"-"}
execute as @a[scores={time=20..}] run function system:event/death/failed {reason:" war zu lange auf einer Platform"}
execute as @a[scores={time=20..}] run scoreboard players reset @s time
scoreboard players remove @a[scores={cooldown=1..}] cooldown 1
effect give @a minecraft:saturation infinite 255 true
effect give @a minecraft:resistance infinite 255 true
execute as @a[x=15,dx=4,y=39,dy=7,z=-31,gamemode=!spectator] run function system:event/death/failed {"reason":" wurde gegrillt"}