#built using mc-build (https://mcbuild.dev/)

execute as @a if score @s wins = $max points at @s if score @s wins matches 1.. run function main:temp/sub/text/_hidden_/win
tag @a remove processed
function main:restart
tag @a remove ingame
tag @a remove inround
scoreboard objectives remove wins
clear @a
tp @a 0 33 7 180 2
title @a actionbar {"text":"GAME ENDED","bold":true,"color":"red"}