Filled Commands without a "/" if user meets criteria (double layered)

Discussion in 'Plugin Requests' started by Dark_Serpent, Sep 22, 2015.

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

    I Al Istannen

    @Dark_Serpent If no folder is generated there must be an error. Could you post your server log. I have sth in mind, I will check it.

    EDIT: Ok, i will guess the error was "Unsupported Major.Minor version: 52". I compiled with Java 8, you were probably using Java 7. Thought I had changed that... Anyways, try redownloading it, i uploaded a new file.
  2. Offline


    That fix worked beautifully! Thank you so much!

    EDIT 1: Would it be possible to allow multiple commands in one string? Just an example, "say" and "tp" being used?

    EDIT 2: It doesn't look like the permissions work. I tried adding "shoutcommands.Example.Greet" to a player using bPermissions but it wouldn't work. I tried giving an individual player access to "worldedit.*" and it worked, so it looks like it's a problem with the way the permissions work in the plugin.

    EDIT 3: I disabled "Care for player permissions" and it still doesn't work. Furthermore, whenever any player types in chat, they can't say anything without it saying "You don't have permission to use this plugin."
    Last edited: Oct 10, 2015
  3. Offline

    I Al Istannen

    @Dark_Serpent 2. + 3. Screw me and my unfinished documentations. Players need the permissions "shoutcommands.use" to be able to use spells. You can check that, because the message is a bit different.
    • If you don't have the permission "shoutcommands.use": "&cYou don't have permission to use this plugin".
    • If you dont have the permission to cast a spell: "&cYou don't have the permission to use this ability"

    To first, what you mean with that? Use "Midus Ice" and "Midus Ice Pillar" in one command?
  4. Offline


    @I Al Istannen
    Ah, thank you!
    And as for multiple commands in one string, say you have:

    - say is now teleporting back to spawn
    - delay 5 #I assume this would be in ticks
    - spawn

    It can be in any format, and it's not really a necessity per se, but it would be a nice addition. Again, thanks for all you've done so far, the plugin is great.
  5. Offline

    I Al Istannen

    @Dark_Serpent What would you do with the arguments the player passes after the command? Append them to all commands? Or to none?
  6. Offline


    Sorry, I'm not quite sure what you mean by this. Could you please elaborate for me?
  7. Offline

    I Al Istannen

    @Dark_Serpent You wanted, that every thing the player types behind his command e.g. "Midus Ice Hey" should get appended to the command. If the command "Midus Ice" was "say Midus Ice", then it would become "say Midus Ice Hey". If you have multiple command in a list, like:
      - "say I greet you, {PLAYERNAME}."
      - "delay 20t 1s"
      - "say You can add delays!"
    Should everything they write be Appended at every command? If they write "Greet Hey", should it become
     - "say I greet you, {PLAYERNAME} Hey"
     - "say You can add delays! Hey"
    or should it stay
     - "say I greet you, {PLAYERNAME}"
     - "say You can add delays!"
  8. Offline


    I can start this right now. I know exactly how I will do this. I will edit with a GitHub repo when I make it. I should be done very soon (2 - 3 days).

    EDIT: Repo:

    EDIT 2: Just realized I didn't even read the thread. I wont make it unless you need me to.
    Last edited: Oct 12, 2015
  9. Offline


    @I Al Istannen
    Ah, thank you, I see what you mean now.
    If it's not too much trouble, let it stay.
    I think @I Al Istannen has it covered. Thank you for the offer, though.
  10. Offline

    I Al Istannen

    @Dark_Serpent I ended up adding a config option to disable or enable it. Consider deleting or renaming your config file to let it generate with the new options. Just redownload it from the link on the first page.
  11. Offline


    It's great! Thank you!

    I hate to bother you even more, but is it possible to add a permission that hides a player's command? Similarly to "cancel message", players with that permission will no longer have their text show up in chat if it's a ShoutCommand.

    Also, is it possible to allow the names of commands in groups to have spaces? i.e. "Greet Hello World!", with "Hello World!" being the command in the group?

    Again, thank you so much for taking up this task even though you're busy.

    EDIT 1: Something I noticed in the update, the minutes have turned into seconds. If I put "30m" is shows up as "30 seconds".

    EDIT 2: It seems if I set it to seconds it maxes out at 60, and if I set it to minutes it'll increase the seconds, 3600 minutes means 4,882 seconds. Is it perhaps registering as ticks?
    Last edited: Oct 14, 2015
  12. Offline

    I Al Istannen

    @Dark_Serpent I haven't got that much time right now, I will try looking in it as soon as possible. Splitting at " " was the easiest way, but I can enhance it. I changed the way it parses the cooldown and delay in this update, thought I had fixed that.

    EDIT: Yes, it was in ticks and it just read the first number. It just ignored the rest...

    EDIT 2: I (hopefully) fixed the error, at least I can't reproduce it and I don't see how it still could happen.
    I added the permission node "shoutcommands.sendnomessage" to NOT send a message when sending a Command Message. This does not default to op and needs to be explicity given to the user.
    I also changed the way it printed out the cooldown. There are now the "{COOLDOWNTIME}" and a new "{COOLDOWNUNIT}" placeholders. The cooldown will automatically be converted in the best possible unit for the value. 1000ms will become 1 second, 60000ms will become 1 minute and so on. You can either recreate the config or just add the "{COOLDOWNUNIT}" placeholder instead of "second(s)".

    Either redownload the file from the previous site or use the link here. (It's the same)
    Last edited: Oct 15, 2015
  13. Offline


    @I Al Istannen

    Thanks again man!

    I noticed another bug though. It seems that if the cooldown exceeds 60 seconds, it'll constantly be stuck at a low amount. It seems to range from saying 1-2 seconds.


    I used the same ability in 1 second intervals and this is what it says.

    At the time of using the ability, the cooldown was set at 60 hours. Other abilities have shown 4 seconds while the cooldown was 5 minutes, etc.
  14. Offline

    I Al Istannen

    @Dark_Serpent Looks like i will need a calm look into it.

    EDIT: I can't reproduce it. Could you post your spells.yml and your config.yml?

    EDIT 2: In theconfig.yml is something new.

    Try recreating it or changing it to this:
    # Message to be send to the player if the command is on cooldown. {COOLDOWNTIME} will be replaced with the cooldowntime and {COOLDOWNUNIT} with the unit (e.g. seconds)
    On cooldown message: "&cThis ability is on cooldown for another {COOLDOWNTIME} {COOLDOWNUNIT}(s)!"
    It looks like it outputs seconds, but wants to output it in days.
    Last edited: Oct 16, 2015
  15. Offline


    @I Al Istannen
    I found the problem. Apparently my old config and the newly generated config got switched. My bad!

    EDIT: After working with the plugin for a while, this is what I've managed to do with it. I thought I'd post it here since you might be interested to see what the plugin being used for.
    Last edited: Oct 17, 2015
  16. Offline

    I Al Istannen

Thread Status:
Not open for further replies.

Share This Page