1. 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!

  2. LOOKING FOR A VERSION OF SKRIPT?

    You can always check out our Wiki for downloads and any other information about Skript!

Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Please help me :(

Discussion in 'Skript' started by DevilZNK, Aug 4, 2020.

Thread Status:
Not open for further replies.
  1. DevilZNK

    DevilZNK Member

    Joined:
    Aug 4, 2020
    Messages:
    3
    Likes Received:
    0
    Hi, I making RPG server (Czech Server)
    and this command not function :emoji_frowning:

    on rightclick:
    if player is holding sugar named "&2test":
    message "&f" to player
    message "&7>>>>>>>>>>>>>>> &f&lMONSTER RPG &7<<<<<<<<<<<<<<<" to player
    message "&f" to player
    message "&e&lUSPESNE JSI ODEMKNUL LOKACI 2" to player
    message "&f" to player
    message "&7>>>>>>>>>>>>>>> &f&lMONSTER RPG &7<<<<<<<<<<<<<<<" to player
    message "&f" to player
    remove 1 sugar named "&2test" from player's inventory
    execute console command "pex user %player% group set warp.lokace.2"

    I want with right click sugar => player got permissions got to new area. please help me?
    I rlly want this :emoji_frowning:
    --- Double Post Merged, Aug 4, 2020, Original Post Date: Aug 4, 2020 ---
    My server have 1.1.2.2 version
    --- Double Post Merged, Aug 4, 2020 ---
    1.12.2
     
  2. MrNygus

    MrNygus Active Member

    Joined:
    Jan 28, 2017
    Messages:
    115
    Likes Received:
    2
    What's a problem?
    Maybe: pex user %player% group set warp.lokace.2 true
     
  3. DevilZNK

    DevilZNK Member

    Joined:
    Aug 4, 2020
    Messages:
    3
    Likes Received:
    0
    Well, but when I click right, nothing happens to the subject, I don't know what error I have there, but if I give / sk reload <name> I don't write any error and that's not how I do it with any scripts in this style, I mean rightclick style
     
  4. SkriptLearner

    SkriptLearner Member

    Joined:
    Jul 21, 2019
    Messages:
    45
    Likes Received:
    0
    Hey DevilZNK,

    Please format your code in code blocks. This helps people who would like to help you read your code and makes the overall proccess quicker and easier.

    The format looks like:

    Code (Text):
    1. Example
    You put your code in it by putting [ CODE] at the start and [ /CODE] at the end of your code without the spaces.

    Hopefully this helps you make your code more readable!
     
  5. DevilZNK

    DevilZNK Member

    Joined:
    Aug 4, 2020
    Messages:
    3
    Likes Received:
    0
    Code (Text):
    1. on rightclick:
    2.             if player is holding sugar named "&2test":
    3.             message "&f" to player
    4.             message "&7>>>>>>>>>>>>>>> &f&lMONSTER RPG &7<<<<<<<<<<<<<<<" to player
    5.             message "&f" to player
    6.             message "&e&lUSPESNE JSI ODEMKNUL LOKACI 2" to player
    7.             message "&f" to player
    8.             message "&7>>>>>>>>>>>>>>> &f&lMONSTER RPG &7<<<<<<<<<<<<<<<" to player
    9.             message "&f" to player
    10.             remove 1 sugar named "&2test" from player's inventory
    11.             execute console command "pex user %player% group set warp.lokace.2"
    12.  
     
  6. SkriptLearner

    SkriptLearner Member

    Joined:
    Jul 21, 2019
    Messages:
    45
    Likes Received:
    0

    Hey DevilZNK,

    In your code you have incorrect indentations. Everything you want to be triggered by the if statement needs to be moved along one indentation. You can find more information on indentations at https://forums.skunity.com/wiki/indentation/.

    Also, try changing the if statement to:
    Code (Text):
    1. if player's held item is sugar named "&2Test"
    (https://en.njol.ch/projects/skript/doc/expressions/#ExprTool)

    I hope this helps!
     
Thread Status:
Not open for further replies.

Share This Page

Loading...