Having trouble with a timer using the scoreboard how would I fix this code?

Having trouble with the following code how can I fix it? **My Summon Enchant ** { "description": "WAKE", "supported_items": "minecraft:iron_axe", "slots": ["mainhand"], "weight": 1, "anvil_cost": 0, "min_cost": { "base": 1, "per_level_above_first": 0 }, "max_cost": { "base": 10, "per_level_above_first": 0 }, "max_level": 1, "effects": { "minecraft:hit_block": [{ "effect": { "type": "minecraft:run_function", "function": "enchantments:run_wither_skeleton_summon" }, "requirements": { "condition": "entity_properties", "entity": "this", "predicate": { "flags": {"is_sneaking": true}} } }] } } MY RUN Wither Skeleton Summon command # If the summoner's score is not 0, send a message execute unless score @s countdown matches 0 run tellraw @s {"text":"You Just Used This!","color":"red"} # If the summoner's score is 0, run the summoning function execute if score @s countdown matches 0 run function enchantments:summon_wither_skeleton My Summon Command # Tag the player to identify the summoner tag @s add summoner # Create the team if it doesn't exist team add my_team # Join the player to the team team join my_team @s # Summon a wither skeleton 1 block below the player and tag it summon minecraft:wither_skeleton ~ ~1 ~ {Tags:["attacker"]} # Play particle effect and sound effect simultaneously at the summoned skeleton's location execute at @e[type=minecraft:wither_skeleton,tag=attacker] run particle minecraft:poof ~ ~1 ~ 0.5 0.5 0.5 0.1 100 force execute at @e[type=minecraft:wither_skeleton,tag=attacker] run playsound minecraft:block.amethyst_block.chime master @a ~ ~1 ~ 0.5 1 # Add the summoned wither skeleton to the player's team execute as @e[type=minecraft:wither_skeleton,tag=attacker] at @s run team join my_team @s # Schedule the function to remove the wither skeleton after 5 seconds schedule function entity_status:remove_wither_skeleton 5s # Set the countdown score to 100 (5 seconds cooldown) scoreboard players set @s countdown 100 # Schedule the tick function to decrement the countdown score schedule function cooldowns:tick 1s # Remove the summoner tag tag @s remove summoner and finally my tick.mcfuncion # Decrease the countdown score for players with a countdown score greater than 0 execute as @a[scores={countdown=1..}] run scoreboard players remove @s countdown 1 and tick.json { "values": ["cooldowns:tick"] }
Continue to help post