tag @e[type=armor_stand,tag=CadeyrnOreStand] remove CadyOre
tag @e[type=armor_stand,tag=CadeyrnOreStand,limit=5,sort=random] add CadyOre
execute as @e[type=armor_stand,tag=CadeyrnOreStand,tag=CadyOre] run function zzzzdonotuse:misc/replacegoldblockcadeyrn
execute as @e[type=armor_stand,tag=CadeyrnOreStand,tag=CadyOre] run execute at @s run tp @s ~ ~1 ~
execute as @e[type=armor_stand,tag=CadeyrnOreStand,tag=CadyOre] run execute at @s run execute if block ~ ~1 ~ shroomlight run kill @s

scoreboard players remove @e[type=armor_stand,name=CadeyrnFight] KyuDummy 1

execute if entity @e[type=armor_stand,name=CadeyrnFight,scores={KyuDummy=1..}] run function zzzzdonotuse:cadeyrn/attacks/deathanim/fillores