execute as @s[tag=!FoundADTag] run function zzzzdonotuse:spell/imbuemodify/checkadstatslot
scoreboard players set @s ADCheck 0
execute as @s run function zzzzdonotuse:spell/imbuemodify/checkmaxhpstatslot
execute as @s[tag=!FoundHPTag] run function zzzzdonotuse:spell/imbuemodify/checkmaxhpstatslot
scoreboard players set @s MaxHPCheck 0


execute store result score @s[tag=FoundHPTag0] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[0].Amount 100
execute store result score @s[tag=FoundHPTag1] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[1].Amount 100
execute store result score @s[tag=FoundHPTag2] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[2].Amount 100
execute store result score @s[tag=FoundHPTag3] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[3].Amount 100
execute store result score @s[tag=FoundHPTag4] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[4].Amount 100
execute store result score @s[tag=FoundHPTag5] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[5].Amount 100
execute store result score @s[tag=FoundHPTag6] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[6].Amount 100
execute store result score @s[tag=FoundHPTag7] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[7].Amount 100
execute store result score @s[tag=FoundHPTag8] MaxHPCheck run data get entity @s Item.tag.AttributeModifiers[8].Amount 100
###
execute store result score @s[tag=FoundADTag0] ADCheck run data get entity @s Item.tag.AttributeModifiers[0].Amount 100
execute store result score @s[tag=FoundADTag1] ADCheck run data get entity @s Item.tag.AttributeModifiers[1].Amount 100
execute store result score @s[tag=FoundADTag2] ADCheck run data get entity @s Item.tag.AttributeModifiers[2].Amount 100
execute store result score @s[tag=FoundADTag3] ADCheck run data get entity @s Item.tag.AttributeModifiers[3].Amount 100
execute store result score @s[tag=FoundADTag4] ADCheck run data get entity @s Item.tag.AttributeModifiers[4].Amount 100
execute store result score @s[tag=FoundADTag5] ADCheck run data get entity @s Item.tag.AttributeModifiers[5].Amount 100
execute store result score @s[tag=FoundADTag6] ADCheck run data get entity @s Item.tag.AttributeModifiers[6].Amount 100
execute store result score @s[tag=FoundADTag7] ADCheck run data get entity @s Item.tag.AttributeModifiers[7].Amount 100
execute store result score @s[tag=FoundADTag8] ADCheck run data get entity @s Item.tag.AttributeModifiers[8].Amount 100
###
scoreboard players add @s[scores={MaxHPCheck=-799..}] ADCheck 100
scoreboard players remove @s[scores={MaxHPCheck=-799..}] MaxHPCheck 200
###
execute store result entity @s[tag=FoundHPTag0] Item.tag.AttributeModifiers[0].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag0,scores={MaxHPCheck=-10000..}] MaxHPCheck
execute store result entity @s[tag=FoundHPTag1] Item.tag.AttributeModifiers[1].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag1,scores={MaxHPCheck=-10000..}] MaxHPCheck
execute store result entity @s[tag=FoundHPTag2] Item.tag.AttributeModifiers[2].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag2,scores={MaxHPCheck=-10000..}] MaxHPCheck
execute store result entity @s[tag=FoundHPTag3] Item.tag.AttributeModifiers[3].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag3,scores={MaxHPCheck=-10000..}] MaxHPCheck
execute store result entity @s[tag=FoundHPTag4] Item.tag.AttributeModifiers[4].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag4,scores={MaxHPCheck=-10000..}] MaxHPCheck
execute store result entity @s[tag=FoundHPTag5] Item.tag.AttributeModifiers[5].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag5,scores={MaxHPCheck=-10000..}] MaxHPCheck
execute store result entity @s[tag=FoundHPTag6] Item.tag.AttributeModifiers[6].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag6,scores={MaxHPCheck=-10000..}] MaxHPCheck
execute store result entity @s[tag=FoundHPTag7] Item.tag.AttributeModifiers[7].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag7,scores={MaxHPCheck=-10000..}] MaxHPCheck
execute store result entity @s[tag=FoundHPTag8] Item.tag.AttributeModifiers[8].Amount double 0.01 run scoreboard players get @s[tag=FoundHPTag8,scores={MaxHPCheck=-10000..}] MaxHPCheck
###
execute store result entity @s[tag=FoundADTag0] Item.tag.AttributeModifiers[0].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag0,scores={ADCheck=1..}] ADCheck
execute store result entity @s[tag=FoundADTag1] Item.tag.AttributeModifiers[1].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag1,scores={ADCheck=1..}] ADCheck
execute store result entity @s[tag=FoundADTag2] Item.tag.AttributeModifiers[2].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag2,scores={ADCheck=1..}] ADCheck
execute store result entity @s[tag=FoundADTag3] Item.tag.AttributeModifiers[3].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag3,scores={ADCheck=1..}] ADCheck
execute store result entity @s[tag=FoundADTag4] Item.tag.AttributeModifiers[4].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag4,scores={ADCheck=1..}] ADCheck
execute store result entity @s[tag=FoundADTag5] Item.tag.AttributeModifiers[5].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag5,scores={ADCheck=1..}] ADCheck
execute store result entity @s[tag=FoundADTag6] Item.tag.AttributeModifiers[6].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag6,scores={ADCheck=1..}] ADCheck
execute store result entity @s[tag=FoundADTag7] Item.tag.AttributeModifiers[7].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag7,scores={ADCheck=1..}] ADCheck
execute store result entity @s[tag=FoundADTag8] Item.tag.AttributeModifiers[8].Amount double 0.01 run scoreboard players get @s[tag=FoundADTag8,scores={ADCheck=1..}] ADCheck







