$scoreboard players remove @e[type=#main:enemies,tag=enemy] $(id)_$(character)_$(type)_hit_cooldown 1
execute as @s at @s run function main:mechanics/artifacts/inputs/on_proj

# $execute at @s positioned $(positioned_1) if entity @n[tag=!$(id)_$(character)_$(type)_hit,type=#main:enemies,tag=enemy,tag=!fake,tag=enemy,dx=0] positioned $(positioned_2) if entity @s[dx=0] run return run scoreboard players remove @s pierce 1

$execute at @s run function main:mechanics/arrow/check {"id":$(id),"character":$(character),"type":$(type),"particle":"$(particle)","positioned":"$(positioned)","gravity":$(gravity),"gravity_strength":"$(gravity_strength)","homing":$(homing),"homing_strength":$(homing_strength),"speed":$(speed),"particle":"$(particle)","folder_location":"$(folder_location)"}

execute as @s[scores={projectile=1..}] run scoreboard players remove @s projectile 1