Solved Can someone help me in one little thing?

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

St0medy

Member
Nov 26, 2017
18
1
3
21
In this code, when I put the command, but it does not give me the money of all the items I have, that is, if I have 40 leather does not give me 25 x 40, it gives me only 25 for all

Thanks so much.

code_language.skript:
command /FixerDevSKxe:
    permission: porros.shop
    trigger:
        set {_amount} to 0
        loop all items in player's inventory:
            if loop-item is leather:
                set {_n} to "%loop-item%"
                set {_t::*} to {_n} split at " "
                if {_t::2} is not set:
                    add 1 to {_amount}
                else:
                    set {_final} to {_t::1} parsed as an integer
                    add {_final} to {_amount}
        if {_amount} is bigger than 0:
            remove all leather from player's inventory
            add 25 to player's balance
            send player title "&5You get" with subtitle "&a25$ Dolars" for 3 seconds
        else:
            message "{@Prefix} {@MsgPorros}"
 
Last edited:
code_language.skript:
add 25*{_amount} to player's balance
This?
 
code_language.skript:
add 25*{_amount} to player's balance
This?

Yea Thanks, and u know this

That is to say that in the title the money that has sold

code_language.skript:
send player title "&5You get" with subtitle "&a25$ Dolars" for 3 seconds
 
Yea Thanks, and u know this

That is to say that in the title the money that has sold

code_language.skript:
send player title "&5You get" with subtitle "&a25$ Dolars" for 3 seconds
code_language.skript:
send player title "&5You get" with subtitle "&a%25*{_amount}%$ Dolars" for 3 seconds
 
code_language.skript:
send player title "&5You get" with subtitle "&a%25*{_amount}%$ Dolars" for 3 seconds

Thank you very much, you doubt resolved, I'll leave the post like this, in case someone who has the same doubts, can be of help

Can you close the section?
 
Status
Not open for further replies.