execute as @a[tag=playing] at @s run function pctf:logic/player/main
# I added this below cuz this is the general loop, I could add it within one main and make it better but I decided to just split it
execute as @a at @s run function pctf:logic/player/loop
# To make it easier for myself lol.

execute as @a[tag=!playing] at @s run function pctf:logic/lobby/no_team

execute as @e[type=marker,tag=map_lobby,tag=in_game,scores={countdown=1..}] at @s run function pctf:logic/game/countdown
execute as @e[type=marker,tag=map_lobby,tag=in_game,scores={countdown=0}] at @s run function pctf:logic/game/main

execute as @a[tag=end_game] run function pctf:logic/game/end/loop