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.

Solved Skript help - Disable plugin specific commands.

Discussion in 'Skript' started by CustomWorldYT, Jun 22, 2018.

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

    CustomWorldYT Member

    Joined:
    Jun 17, 2018
    Messages:
    15
    Likes Received:
    0
    I develop a FreeOP mod in a skript, and I want to ask if it's possible to block every command that contains colons, I don't want OPs to execute commands like /minecraft:advancement blah blah. Is it possible?[/B]

    Skript Version: 2.2 dev36 (Pre-release)
    Skript Author: CustomWorldYT
    Minecraft Version: 1.12.2

    ---
    Code example:

    Code (Skript):
    1.  
    2. on command /minecraft:<any argument there>:
    3.         message "&7Plugin specific commands are disabled."
    4.  
    Errors on Reload:

    Code (Skript):
    1. None ¯\_()_/¯
    Console Errors:

    Code (Skript):
    1. None... ¯\_()_/¯
    Other Useful Info:

    Addons using (including versions):
    None there too ツ

    Troubleshooting:

    Have you tried searching the docs? Yes
    Have you tried searching the forums? Yes
    What other methods have you tried to fix it?
    Um, no idea.
     
  2. Best Answer:
    Post #2 by TPGamesNL, Jun 22, 2018
  3. TPGamesNL

    Supporter Addon Developer Dev Programme

    Joined:
    Jan 20, 2018
    Messages:
    1,501
    Likes Received:
    107
    Medals:
    Try this:
    Code (Skript):
    1. on command:
    2.     command contains ":"
    3.     cancel event
    4.     message "&7Plugin specific commands are disabled."
     
    • Winner Winner x 1
  4. CustomWorldYT

    CustomWorldYT Member

    Joined:
    Jun 17, 2018
    Messages:
    15
    Likes Received:
    0
    Thank you, this code helped me. :emoji_slight_smile:
     
Thread Status:
Not open for further replies.

Share This Page

Loading...