$execute as @s[scores={svm_ep.mana=$(cost)..}] run tag @s add can_use


$execute as @s[tag=!can_use] run function svm_ep:items/power_ability/ui {"color":"gray","cant_use":"true","ability_name":"$(ability_name)"}
$execute as @s[tag=can_use] run function svm_ep:items/power_ability/ui {"color":"$(color)","cant_use":"false","ability_name":"$(ability_name)"}
tag @s remove can_use