Sell skript have no error but not working

  • 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!

Status
Not open for further replies.

LoneDragon38

New Member
Oct 10, 2020
5
0
1
25
does anyone can help me with this skript:

options:
prefix: &a&l[Sell]
items-names : "Wheat Seeds" and "Melon Seeds" and "Pumpkin Seeds" and "Beetroot Seeds" and "Cactus" and "Sugar Cane"
items-prices : 3 and 4 and 5 and 6 and 7 and 8
items : wheat and melon and pumpkin and cactus and sugar cane

command /sell:
trigger:
set {_money} to 0
set {_counter} to 1
set {_temp1::*} to {@items-names}
set {_temp2::*} to {@items-prices}
loop {@items}:
set {_money} to {_money} + (amount of loop-value named "%{_temp1::%{_counter}%}%" in player's inventory * {_temp2::%{_counter}%})
remove all loop-value named "%{_temp1::%{_counter}%}%" from player's inventory
add 1 to {_counter}
play sound "ENTITY_EXPERIENCE_ORB_PICKUP" to player
send title "{@prefix} &aSuccess!" with subtitle "&3You sold &a%{_money}%&3!" for 1 second
add {_money} to player's balance

There have no errors but it's not working. Please help
 
Status
Not open for further replies.