tag @e[tag=Board,tag=Red,tag=!Alive] remove Red
tag @e[tag=Board] remove WasRed
tag @e[tag=Board] remove WasAlive
tag @e[tag=Board,tag=Red] add WasRed
tag @e[tag=Board,tag=Alive] add WasAlive
execute as @e[tag=Board,tag=!Alive,tag=WillLive] run tag @s add Alive
execute as @e[tag=Board,tag=Alive,tag=WillDie] run tag @s remove Alive
execute as @e[tag=Board,tag=Alive,tag=BecomeRed] run tag @s add Red
tag @e[tag=Board,tag=!Alive] remove Red
tag @e[tag=Board] remove WillLive
tag @e[tag=Board] remove WillDie
tag @e[tag=Board] remove BecomeRed
function main:updateboard