command /shop:
trigger:
open chest with 1 rows named "&cShop" to player
if player's money is less than 50:
format slot 0 of player with diamond sword named "&c&lDiamond Sword" with lore "&e&oClick here to purchase a diamond sword.||||&fPrice: &a$&c50||||&cYou can not afford||&cthis ability!||&e&oYou need: &a$&c%50-(money of player)%" to be unstealable
if player's money is more than or equal to 50:
format slot 12 of player with diamond sword named "&c&lDiamond Sword" with lore "&e&oClick here to purchase a diamond sword.||||&fPrice: &a$&c50||||&dBalance: &c%player's money%||&dAfter Purchase: &c$%(money of player)-50%" to close then run [make console execute command "give %player% diamond_sword 1"]->[subtract 50 from player's money]->[send "&aYou bought a diamond sword for &c$50"]
don't work
trigger:
open chest with 1 rows named "&cShop" to player
if player's money is less than 50:
format slot 0 of player with diamond sword named "&c&lDiamond Sword" with lore "&e&oClick here to purchase a diamond sword.||||&fPrice: &a$&c50||||&cYou can not afford||&cthis ability!||&e&oYou need: &a$&c%50-(money of player)%" to be unstealable
if player's money is more than or equal to 50:
format slot 12 of player with diamond sword named "&c&lDiamond Sword" with lore "&e&oClick here to purchase a diamond sword.||||&fPrice: &a$&c50||||&dBalance: &c%player's money%||&dAfter Purchase: &c$%(money of player)-50%" to close then run [make console execute command "give %player% diamond_sword 1"]->[subtract 50 from player's money]->[send "&aYou bought a diamond sword for &c$50"]
don't work