$function main:mechanics/effects/remove {"effect":$(effect)}
$tag @s add $(character)_$(effect)
$scoreboard players add @s[scores={$(effect)_s=..20}] $(effect)_s $(duration)
$scoreboard players add @s[scores={$(effect)_s=..20}] $(effect)_s 1
$scoreboard players set @s $(effect)_t 19

$function main:mechanics/artifacts/inputs/effect_apply {"character":"$(character)"}

execute if entity @a[tag=!game_started] run return fail
$scoreboard players add .$(effect)_apply progression 1
$scoreboard players add .$(effect)_s_total progression $(duration)