execute if entity @s[scores={decay=1}] run effect give @e[type=!player,distance=..5,nbt=!{HurtTime:0s}] wither 4 0
execute if entity @s[scores={decay=2}] run effect give @e[type=!player,distance=..5,nbt=!{HurtTime:0s}] wither 4 1
execute if entity @s[scores={decay=3}] run effect give @e[type=!player,distance=..5,nbt=!{HurtTime:0s}] wither 4 2
execute if entity @s[scores={decay=4}] run effect give @e[type=!player,distance=..5,nbt=!{HurtTime:0s}] wither 4 3