execute unless score #KyuQStructuresInstall KyuDummy5 matches 1 run effect give @s[tag=InvisSpell2,tag=K,tag=!InvisReset] minecraft:invisibility 60 0
execute unless score #KyuQStructuresInstall KyuDummy5 matches 1 run effect give @s[tag=InvisSpell2,tag=K,tag=!InvisReset,tag=InvisUpgrade2] minecraft:invisibility 240 0
execute unless score #KyuQStructuresInstall KyuDummy5 matches 1 run tellraw @s[tag=InvisSpell2,tag=!InvisReset] ["",{"text":"Invisibility has been activated!","color":"green"}]
execute unless score #KyuQStructuresInstall KyuDummy5 matches 1 run tellraw @s[tag=InvisSpell2,tag=InvisReset] ["",{"text":"You have already used the Invisibility spell today - You may use it again tomorrow.","color":"yellow"}]
execute unless score #KyuQStructuresInstall KyuDummy5 matches 1 run tag @s[tag=InvisSpell2,tag=K,tag=!InvisReset] add InvisReset
#scoreboard players set @s KyuSpells 0

execute unless score #KyuQStructuresInstall KyuDummy5 matches 1 run tag @s remove KyuLatentInvisSpell




##structures version


execute if score #KyuQStructuresInstall KyuDummy5 matches 1 run effect give @s[tag=InvisSpell2,tag=K,tag=!InvisReset,level=5..] minecraft:invisibility 60 0
execute if score #KyuQStructuresInstall KyuDummy5 matches 1 run effect give @s[tag=InvisSpell2,tag=K,tag=!InvisReset,tag=InvisUpgrade2,level=5..] minecraft:invisibility 120 0
execute if score #KyuQStructuresInstall KyuDummy5 matches 1 run tellraw @s[tag=InvisSpell2,tag=!InvisReset,level=5..] ["",{"text":"Invisibility has been activated!","color":"green"}]
execute if score #KyuQStructuresInstall KyuDummy5 matches 1 run tellraw @s[tag=InvisSpell2,level=0..4] ["",{"text":"You do not have the required xp to cast this.","color":"yellow"}]
execute if score #KyuQStructuresInstall KyuDummy5 matches 1 run xp add @s[tag=InvisSpell2,level=5..] -55 points

execute if score #KyuQStructuresInstall KyuDummy5 matches 1 run tag @s remove KyuLatentInvisSpell














execute if entity @e[type=marker,distance=..40,tag=KyuBigPyramid] run tellraw @s[tag=InvisSpell2] ["",{"text":"P.S. - Invisibility doesn't help you against the plethora of traps that await you in here.","color":"gold"}]