I can't seem to find the GUI slot while using the function. Heres my skript:
on right click on villager:
if display name of villager is "Blacksmith":
open chest with 3 rows named "&7&lSmithing GUI" to player
... # other stuff here that dosent matter to the problem at hand
format slot 14 of player with anvil named "&8&lSmithing Tool" with lore "&a", "&7Put a item in the empty slot", "&7and click the anvil.", "&a", "&7This will add a bonus to your", "&7selected item." , "&a" and "&c&lWARNING: IRREVERSIBLE" to run [SmithTest(player)]
function SmithTest(p: player):
set {_u} to uuid of {_p}
set {_Item} to slot 12 of {_p} # This is the line im having problems with
if {_item} is not air:
give {_p} {_item}
else:
send "&cWrong slot :/" to {_p}
I want to give the player an item when they add something to slot 12 OF THE GUI.