buyable kits issue

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

UavzXXX__

Member
May 4, 2023
2
0
1
22
i downloaded addon Ersatz so i can use placeholders from other plugins. i loaded placeholder %vault_eco_balance_fixed% but when i try to buy a kit it says i don't have enought money, so could you help me please? my balance was 8640$

here is code:
else if event-slot is 36:
set {vault_eco_balance_fixed} to placeholder "vault_eco_balance_fixed"
if {vault_eco_balance_fixed} > 200:
close player's inventory
give player netherite helmet
give player netherite chestplate
give player netherite leggings
give player netherite boots
give player netherite sword
give player bow
give player 32 arrows
give player 64 cooked beef
send "{@prefix}&aВи успішно забрали &7Залізний кіт&a!" to player
else:
send "{@prefix}&cУ вас недостатньо коштів для покупки &1Незеритового кіта&c!" to player
send "{@prefix}&eУ вас &a%{vault_eco_balance_fixed}%$&e, а для покупки &1Незеритового кіта вам потрібно мати на власному рахунку не менше &a200$&e!" to player
cancel event
 
i downloaded addon Ersatz so i can use placeholders from other plugins. i loaded placeholder %vault_eco_balance_fixed% but when i try to buy a kit it says i don't have enought money, so could you help me please? my balance was 8640$

here is code:
else if event-slot is 36:
set {vault_eco_balance_fixed} to placeholder "vault_eco_balance_fixed"
if {vault_eco_balance_fixed} > 200:
close player's inventory
give player netherite helmet
give player netherite chestplate
give player netherite leggings
give player netherite boots
give player netherite sword
give player bow
give player 32 arrows
give player 64 cooked beef
send "{@prefix}&aВи успішно забрали &7Залізний кіт&a!" to player
else:
send "{@prefix}&cУ вас недостатньо коштів для покупки &1Незеритового кіта&c!" to player
send "{@prefix}&eУ вас &a%{vault_eco_balance_fixed}%$&e, а для покупки &1Незеритового кіта вам потрібно мати на власному рахунку не менше &a200$&e!" to player
cancel event
I'm not sure what the issue could be, but I'll teach you something, a developer's mindset let's say, debug, check the value of vault_eco_balance_fixed variable, like this
Code:
command /test:
    trigger:
        set {vault_eco_balance_fixed} to placeholder "vault_eco_balance_fixed"
        send "%{vault_eco_balance_fixed}%"
 
I'm not sure what the issue could be, but I'll teach you something, a developer's mindset let's say, debug, check the value of vault_eco_balance_fixed variable, like this
Code:
command /test:
    trigger:
        set {vault_eco_balance_fixed} to placeholder "vault_eco_balance_fixed"
        send "%{vault_eco_balance_fixed}%"
i already tested a couple of times its working but still have issue here is output example:
you don't have enough money to buy this kit
your balance is 8640 and you need 200 to buy that kit