Hi, so I've coded a custom shop (which I'm not going to put the source code into public circulation), and I can't figure out how to subtract from a variable and give items.
Here's my code so far (without the shop).
It has an error with the take 10 from balance bit, and I've tried changing take to subtact, it needs to take 10 from the balance variable and give the player a leather helmet.
Thanks,
- TheCringleYT
Here's my code so far (without the shop).
code_language.skript:
command /shopbuy <text>:
trigger:
if arg-1 is "leatherhelmet":
if {balance::%player%} <= 10:
take 10 from {balance::%player%}
It has an error with the take 10 from balance bit, and I've tried changing take to subtact, it needs to take 10 from the balance variable and give the player a leather helmet.
Thanks,
- TheCringleYT