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!


    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.

how to run an argument

Discussion in 'Skript' started by mrclipse, Sep 21, 2021.

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

    mrclipse Member

    Sep 18, 2021
    Likes Received:
    Im making a command callled /run [<text>], and I want it to run the skript the player inputs for example the player inputs: /run message "test" I want it to return test in the chat

    I tried something but it doesn't work
    Code (Text):
    1. command /run [<text>]:
    2.     trigger:
    3.         run arg-1
  2. Minecoll_YT

    Supporter Forums Helper

    Dec 2, 2018
    Likes Received:
    I don't think there is an effect for this, but you can use the build in skript feature (can be found in the config)
    Code (Text):
    1. enable effect commands: false
    2. effect command token: !
    3. # If 'enable effect commands' is set to true, chat messages starting with the 'effect command token' will be interpreted as effects and executed.
    4. # The token can be longer than a single character, but it should not start with '/' as that starts a command.
    5. # A player needs the permission "skript.effectcommands" to use such commands,
    6. # which does not default to OPs since these commands can do severe damage to the world or crash the server (see below).
    7. # Some example commands which can be used if this setting is enabled:
    8. #    !heal player - heals the player (doesn't do anything if used from the console)
    9. #    !repair tool - repairs the currently held item
    10. #    !broadcast "<red>Please read the rules!" - if you want to get rid of the quotes you have to define a custom command
    11. #    !set time to 6:00 - sets the time in the current world
    12. # The command can also be abused, so only give the permission to trusted players, like owners & co-owners:
    13. #    !set player's balance to 999999999 - when a compatible economy plugin is installed, this will give the command sender as much money as desired
    14. #    !create explosion of force 10000 - likely crashes the server or at least hangs it up for a long time
    15. #    !ban all players - as the effect implies
    • Like Like x 1
  3. Mr_Allawi_

    Mr_Allawi_ Member

    Sep 20, 2021
    Likes Received:
    command /run [<text>]
    if arg-1 is not set:
    #do stuff
    if arg-1 is "test":
    #do stuff
    if arg-1 is set:
    #do stuff
Thread Status:
Not open for further replies.

Share This Page