CustomCommands ◆ With infinite custom children ! 2.5.0

Create unlimited custom commands with several actions ! [1.7-1.13]

  1. PYRRH4
    Tested Minecraft Versions:
    • 1.7
    • 1.8
    • 1.9
    • 1.10
    • 1.11
    • 1.12
    • 1.13
    Source Code:
    https://github.com/PYRRH4/CustomCommands
    Languages Supported:
    English, French, Hungarian (default provided files)
    [​IMG] [​IMG]

    [​IMG]
    [​IMG]
    CustomCommands is a plugin that allows you to create your own commands through a simple configuration system ! You can also use it to override other commands like /spawn or /plugins.

    Feel free to send me ideas to improve the plugin !

    [​IMG]
    • Simple configuration system !
    • Currently 11 actions that you can repear as many times as you want !
    • Add permissions nodes to your commands !
    • Add infinite children to your commands !
    • Add a delay to your commands !
    • Multiple aliases for each arguments and child !
    • Plugin reload system !
    • ... and more !
    Every aspect of the configuration is explained in the "customcommands_commands.yml" file. There are also some simple and complex examples.

    [​IMG]
    • Spigot 1.7.2, 1.7.9, 1.7.10, 1.8.8, 1.9.4, 1.10.2, 1.11.2, 1.12.2 or 1.13.2 (others versions may work but it's not guaranteed, for example custom Spigot versions like Paper)
    • Java 7 and up
    • Latest version of PyrCore
    [​IMG]
    • /customcommands reload (permission customcommands.admin) : reload the plugin
    • /customcommands saveitem|setitem --item [id] (permission customcommands.admin) : save an item
    • /customcommands savelocation|saveloc|setlocation|setloc --location|loc|l [id] (permission customcommands.admin) : save a location
    Command alias : /customcommands, /ccmd

    [​IMG]

    Code (Text):

    #----------------------------------------------------------------------------------------------------
    # Configuration for your custom commands
    #----------------------------------------------------------------------------------------------------
    # Configurations details and description for a command (see the examples below to understand exactly what it does and how to use it)
    #   - (mandatory) aliases (list) : all the aliases the player can type to use your command. The first alias of the list is the one that will be used in display texts (for example, help).
    #   - (mandatory) arguments (config section) : you'll add the arguments patterns you want. If you don't want the player to be able to enter arguments, you'll add a simple arguments object with an empty pattern.
    # And that's all for the command itself. If you don't specify any arguments nobody will be able to perform the command, even with no arguments. See below for examples.
    #----------------------------------------------------------------------------------------------------
    # Configuration details and description for arguments (see the example below to understand exactly what it does and how to use it)
    #   - (mandatory) pattern (text) : the pattern for the command (see just below for explanations, 'Arguments patterns')
    #   - (mandatory) description (text) : a description of the command (display use only)
    #   - (optional) permission (text) : a permission required to use the command
    #   - (optional) worlds (list) : if you specify this, the arguments will only work in those worlds
    #   - (optional) cooldown (number) : a number of seconds that the player will have to wait to run the arguments again
    #   - (mandatory) perform (section) : a list of actions (see details below) that will be executed when the player runs the arguments
    #----------------------------------------------------------------------------------------------------
    # Arguments patterns
    # This is very important to understand, and it's easier than it looks.
    # A pattern is a text, between ''. It can be from an empty string (so the command can be performed with no arguments entered) to a complex pattern with default values.
    #
    # Every word of a pattern can be :
    #   - any word : the player will have to type the exact word (case doesn't matter though)
    #   - a number : [integer] (the player can type any integer he wants)
    #   - a decimal number : [double] (the player can type any double he wants)
    #   - a player : [player] (the player can type any player name he wants)
    #   - an online player : [player-online] (the player can type any online player name he wants)
    #   - a string : [string] (the player can type any word)
    #   - a sized string : [string:{min}:{max}] (the player can type any word within a range)
    #   - a phrase : [phrase] (can be added at the end only) (the player can type any words he wants (technically infinite but minecraft limit the commands size so most likely not more than 50 words)
    #
    # It's important to distinguish the MODEL arguments (the ones that can be filled with anything or something specific, the ones between []) and the STRING arguments (the one that the player has to enter fully)
    #
    # STRING arguments caracteristics :
    # - You can separate argument aliases with |
    #   --> example of pattern with aliases : 'teleport|tp [player]' (the command can be used by typing either 'teleport [player]' or 'tp [player]'
    # - You can NOT specify a default value with $
    # - You can NOT specify a description in help with %
    #
    # MODEL argument notes :
    # - You must specify a description with % to indicate what the argument is useful for. All _ will be replaced by spaces.
    #   --> example of correct MODEL argument : 'teleport [player]%target_player' (the command will display in help as 'teleport [target player]')
    # - You can specify a default value with $ so it'll mean that the argument is optional.
    #   Optional arguments are not required to type and if they're not typed the default value is used instead.
    #   You can NOT add required (non-optional) arguments after an optional argument.
    #   --> example of pattern with optional argument : 'give [player] stone [integer]$64' (the command can be used by typing either 'give [player] stone [integer]' or 'give [player]' (in that second case 64 will
    #       be used because the sender didn't specify that optional argument))
    #   --> Please note that this example is simplified and cannot be used as it because the descriptions of MODEL arguments are missing.
    #
    #----------------------------------------------------------------------------------------------------
    # Actions that you can use :
    #
    #  type: send message
    #  data:
    #    - target ('player', 'everyone', '{arg:[NUMBER]}')
    #    - message line 1 (placeholders : {args}, {player}, &7{receiver}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included]})
    #    - message line 2 (placeholders : {args}, {player}, &7{receiver}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included]})
    #    - ... etc
    #
    #  type: wait ticks
    #  data:
    #    - delay in ticks
    #
    #  type: execute commands for
    #  data:
    #    - command 1 (placeholders : {args}, {player}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included]})
    #    - command 2 (placeholders : {args}, {player}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included]})
    #    - ... etc
    #
    #  type: execute commands as
    #  data:
    #    - target ('player', 'everyone', '{arg:[NUMBER]}')
    #    - command 1 (placeholders : {args, {player}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included]})
    #    - command 2 (placeholders : {args, {player}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included]})
    #    - ... etc
    #
    #  type: send title
    #  data:
    #    - target ('player', 'everyone', '{arg:[NUMBER]}')
    #    - title (placeholders : {args, {player}, &7{receiver}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included]})
    #    - subtitle (placeholders : {args, {player}, &7{receiver}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included]})
    #    - fadein in ticks
    #    - duration in ticks
    #    - fadeout in ticks
    #
    #  type: send actionbar
    #  data:
    #    - target ('player', 'everyone', '{arg:[NUMBER]}')
    #    - the action bar (placeholders : {args, {player}, &7{receiver}, {arg:[NUMBER]}, {args:[STARTING NUMBER, included])
    #
    #  type: give item
    #  data:
    #    - target ('player', 'everyone', '{arg:[NUMBER]}')
    #    - the item name (when you saved it with /ccmd saveitem [name])
    #
    #  type: teleport
    #  data:
    #    - target ('player', 'everyone', '{arg:[NUMBER]}')
    #    - the location name (when you saved it with /ccmd saveloc [name])
    #
    #  type: change gamemode
    #  data:
    #    - target ('player', 'everyone', '{arg:[NUMBER]}')
    #    - the gamemode id (0 = survival, 1 = creative, 2 = adventure, 3 = spectator (1.8+))
    #
    #  type: change tab
    #  data:
    #    - target ('player', 'everyone', '{arg:[NUMBER]}')
    #    - header
    #    - footer
    #
    #----------------------------------------------------------------------------------------------------
    #----------------------------------------------------------------------------------------------------
    # Example 1 : a simple command that overrides the existing spawn commands
    #----------------------------------------------------------------------------------------------------
    spawn:
     
      # Aliases : the command can be used with /spawn or /gotospawn
      aliases:
        - spawn
        - gotospawn
     
      # Arguments : here we don't need argument so we only add one pattern with empty args
      arguments:
        1:
          # Pattern : we don't need arguments, so it's empty
          pattern: ''
          # Description : arguments description ; what is that command going to do if you enter those arguments
          description: go to the spawn
          # Permission : the players will need to have the permission to use the command with those arguments
          permission: myserver.permission.spawn
          # Cooldown : we don't want the player to spam this command
          cooldown: 15
          # Perform : actions that will be performed when the player uses the command with those arguments
          perform:
            1:
              type: teleport
              data:
                - player
                - my_spawn_location
            2:
              type: send message
              data:
                - player
                - '&aAlright {player}, you''re at spawn !'
    #----------------------------------------------------------------------------------------------------
    # Example 2 : a command that shows informations about the server
    #----------------------------------------------------------------------------------------------------
    helpserver:
      # Aliases : the command can be used with /helpserver
      aliases:
        - helpserver
     
      # Arguments
      arguments:
     
        # First arguments : help about the PVP. The full command to type will be /helpserver pvp or /helpserver combat or /helpserver fight
        1:
          pattern: 'pvp|combat|fight'
          description: get informations about the pvp
          perform:
            1:
              type: send message
              data:
                - 'player'
                - '&aThe PVP is active on our server, only in the dedicated PVP arena. You can join the battle with /pvp !'
                - '&7Thanks for using the /helpserver command.'
     
        # Second arguments : help about the shop. The full command to type will be /helpserver shop or /helpserver store
        2:
          pattern: 'shop|store'
          description: get informations about the shop
          perform:
            1:
              type: send message
              data:
                - 'player'
                - '&aWe have a shop available to sell ranks or some cosmetic advantages, so you can support the server and help us to grow. It''s located at www.our-website.com/shop'
                - '&7Thanks for using the /helpserver command.'
        # ... etc. You can add infinite arguments.
    #----------------------------------------------------------------------------------------------------
    # Example 3 : more complex command that uses more arguments and toggles.
    #----------------------------------------------------------------------------------------------------
    complex:
     
      # Aliases : the command can be used with /complex
      aliases:
        - complex
     
      # Arguments
      arguments:
     
        # First arguments : sending a message
        # The full command to type will be /complex say [player] [message (multiple words)]
        # The command will be displayed in help as /complex say [target player] [message]
        1:
          pattern: 'say [player-online]%target_player [phrase]%message'
          description: 'send a message to a player'
          perform:
            1:
              type: send message
              data:
                - '{arg:3}'
                # we send him the arguments starting at argument 3 included
                - '&d[from {player}]: &f{arg:3}'
     
        # Second arguments : sending a poke (single word phrase) to the player, and this word is optional. -->  (poke) is between () below because it's optional
        # The full command to type will be /complex poke [player] (poke)
        # The command will be displayed in help as /complex say [target player] (poke message)
        2:
          pattern: 'poke [player-online]%target_player [string]$defaultpoke%poke_message'
          # not everyone can poke so let's use a permission
          permission: myserver.permission.poke
          description: 'poke a player'
          perform:
            1:
              type: send message
              data:
                - '{arg:3}'
                # we send him the poke ; if the sender entered no third argument, 'defaultpoke' will be sent
                - '&d[poke from {player}]: &f{arg:3}'
     
        # Third arguments : just an example to show you how toggles work
        # The full command to type will be /complex toggle test
        # The command will be displayed in help as /complex toggle test
        3:
          pattern: 'toggle test'
          permission: myserver.permission.toggletest
          description: 'test the toggles'
     
          # If toggle=true, you'll have to specify perform_toggle_false= and perform_toggle_true= instead of only one perform=
          toggle: true
          # If toggle_persistent=true, the toggle state will be kept for each player even after a server restart/reload
          toggle_persistent: true
          # Perform if toggle is currently false for the player when he typed the command
          perform_toggle_false:
            1:
              type: send message
              data:
                - player
                - '&fAnd now, the toggle has been toggled to &atrue &f!'
           
          # Perform if toggle is currently true for the player when he typed the command
          perform_toggle_true:
            1:
              type: send message
              data:
                - player
                - '&fAnd now, the toggle has been toggled to &cfalse &f!'
     

    [​IMG]

    By using this plugin, you agree to the following !
    • The plugin is under this license : http://www.pyrrh4.be/files/licenses/open-source.txt (modify it and redistribute it with my permission)
    • The reviews section is provided for you to give your opinion on the plugin and not to get support / suggest things. See links at the top of the page to get help ! (discord)
    Thanks to arboriginal, for your 5.00€ donation ! <3

Recent Reviews

  1. zPhelan
    zPhelan
    5/5,
    Version: 2.5.0
    A little out of the ordinary config but if you have half a brain you can figure it out. Works well with other plugins that competitors have compatibility issues with.
    1. PYRRH4
      Author's Response
      Amazing ! Thanks for the nice review ^^
  2. arboriginal
    arboriginal
    5/5,
    Version: 2.4.2
    As Driomodo said, the plugin is a bit complex to understand at the beginning, but it allows lots of possibilities. Once understood, it's very easy to add custom commands and no need to restart the server for it.

    If you have questions about how it works, the author replies quickly on his discord.

    Thanks PYRRH4 for sharing this plugin, it works perfectly!
    (tested on paperSpigot 1.13.2)
    1. PYRRH4
      Author's Response
      Thanks a lot :D glad you like it !
  3. Driomodo
    Driomodo
    4/5,
    Version: 2.4.2
    Hard to unterstand how to use the Plugin. The Config for the Plugin itself is hard to configure because if you set a space false then the hole plugin won't work anymore. But still: Very useful and many options! Can even rewrite other Commands like /help or /whitelist
    1. PYRRH4
      Author's Response
      Yeah, that's the struggles of YAML configurations ^^ might also create a wiki if I find some time. Thanks for the review :)
  4. lulek123
    lulek123
    5/5,
    Version: 2.4.2
    Good plugin but please add MySql Support!!!
    Thanks!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    1. PYRRH4
      Author's Response
      Thanks ^^ for features suggestions, please do it on discord with some more details
  5. dh888222
    dh888222
    5/5,
    Version: 2.4.2
    It's a plugin that difficult to use but useful.
    I want to reprint this plugin to a Chinese Website called MCBBS because I'm a Chinese.
    Allowed me?
    1. PYRRH4
  6. Ti2Ga
    Ti2Ga
    5/5,
    Version: 2.4.0
    Very nice Plugin :)

    Very nice that is is free THANKS :D

    not good at English.....
    1. PYRRH4
      Author's Response
      thanks! :D
  7. Nesseley
    Nesseley
    5/5,
    Version: 2.4.0
    Leaving another rating to show support for this great plugin! Sadly it's not updated for 1.13 yet - but I hope it will, as it is the best plugin out there for this purpose.
    1. PYRRH4
      Author's Response
      it'll be soon :)
  8. Stellrow
    Stellrow
    1/5,
    Version: 2.4.0
    The plugin is so bad,has no configuration at all,no guide on how to use it
    overall a terrible plugin thats not worth the download,it even requires a second plugin to work
    1. PYRRH4
      Author's Response
      ok dude, btw the config is in /plugins/PyrCore/ and there's a guide inside it. you would have known that if you had read the first 10 lines of this page.
  9. TheGoldenMCGod
    TheGoldenMCGod
    5/5,
    Version: 2.4.0
    I am being kind of to give this a 5, because I trust you will respond to this. Nothing in my config is work, and even when i delete the examples they still somehow work. When I add things, it doesn't work. PLZ RESPOND
    1. PYRRH4
      Author's Response
      hey there, you can ask in the plugin discussion thread or open an issue on github with more details so i can help you.
  10. MCDanielYT
    MCDanielYT
    5/5,
    Version: 2.4.0
    I like this plugin but can you pls send me a config with the command /find [player] like to say in what world is the player
    1. PYRRH4
      Author's Response
      thanks for that review ; atm this is not possible, i'll add the idea to my todo list