Filled Add permissions to a plugin

Discussion in 'Plugin Requests' started by M4son, Jun 9, 2016.

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

    M4son

    Hello everyone, today I found a MAJOR problem and I need help ASAP. You see, after lot of searching I found a plugin that promotes a player if he clicks a sign starting with [Promote]. I know there are lot of plugins out there doing this job absolutely fine, but this one is special, because it does not only promotes you if you have the required money, but it also checks if you have the required MCMMO level and none of the known plugins do that. So the problem I found is that a non-op player can create and successfully enable a sign by writing [Promote]. What I'm asking you is if you could add 2 permissions to this plugin which are:
    1st: signpromote.use -> If you have this perm, you will be able to use the sign.
    2nd: signpromote.create -> If you have this permission, you will be able to create and enable a sign.

    The plugin can be downloaded from the attached file, and here is where i found the topic with the creation of this plugin: https://bukkit.org/threads/groupmanager-sign-promote.332017/
    Also the source of the plugin is: https://bitbucket.org/AssistDev/sig...src/me/assist/signpromote/Core.java?at=master

    Thanks for taking your time to read this, really appreciate it, and would appreciate it even more if you could add these 2 permissions. Thanks again, have a nice day! :)

    Edit: I know that requesting modifying a plugin isn't allowed, but i can't contact his creator :(
     

    Attached Files:

  2. Offline

    termanator1128

    @M4son if you know that it's not allowed then why are you making a thread its @timtower is most likely just going to lock the thread
     
  3. Offline

    timtower Administrator Administrator Moderator

    And why wouldn't you?
    @Assist
    Just did it,
     
  4. Offline

    M4son

    What do you mean by saying he just did it? :)

    Well I didn't actually know it, I first posted this and then saw the pinned thread lol :p Sorry again :(

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 9, 2016
  5. Offline

    timtower Administrator Administrator Moderator

    I got his attention, contacted him
     
    M4son likes this.
  6. Offline

    M4son

    Oh, thanks a lot man! :D (When I said I couldn't contact him I meant that I was talking to him but he wouldn't reply, anyways thanks again :) )
     
  7. Offline

    timtower Administrator Administrator Moderator

  8. Offline

    M4son

    Yeah, anyway thanks again, you can lock the thread if want. :)
     
  9. @M4son
    Hey there! I apologize for the very late reply, I've had some things to do in real life so I haven't been on Bukkit.

    Anyone is free to modify and redistribute any of my public projects (credit would be appreciated though).

    I can add in the permissions for you if you still need this, however this plugin was made some time ago so I can't guarantee that it will work with the server you are using. The plugin could use some improvements anyways, I made it in a few minutes as a reply to a plugin request.

    You can reply back to this thread :)
     
    Last edited by a moderator: Jun 24, 2016
  10. Offline

    M4son

    Hello, thanks for replying! I still need this plugin, so if you could add these 2 permissions I said, it would be really appreciated. This plugin works like a charm in 1.9, so I don't think I will have compatibility problems. Thanks again and don't rush it, take your time! :D
    EDIT: Could you also change the [Promote] to [Rank], and when you have no permission to use the sign get the message "You already have this, you don't need it"? Thanks again.
     
    Last edited: Jun 24, 2016
  11. @M4son
    Sorry it took a while, I had been sick and busy. I've updated the plugin a bit and added the things you requested, along with some slight improvements. I'm unable to push the updated code to BitBucket due to some Eclipse error, and I'm hopeless with Git, but the source is included in the jar if anyone is interested. Download.

    The format for the promotion sign is still the same. You should include the GroupManager rank on the 2nd line, the money cost on the 3rd line, and the mcMMO power level requirement on the 4th line. The money cost and power level requirements are optional, you can choose to include them or not. Here is an example sign:
    Code:
    [Rank]
    Builder
    $10000
    100 lvl
    The Builder rank would cost 10000 (major) currency of whatever economy plugin you are using, while also having a 100 power level requirement. Note that you will be moved to the group, even from a group superior to this one. Perhaps I should change this?

    I added a configuration file, everything there is self explanatory, but feel free to ask if you're confused about something:
    Code:
    # The text on the sign used to identify a promotion sign.
    signText: "[Rank]"
    
    # Messages sent to players.
    messages:
      noPowerMessage: "&cYou don't have the required power level to buy this rank!"
      noMoneyMessage: "&cYou don't have enough money to buy this rank!"
      sameGroupMessage: "&cYou are already in the &4<group>&c group!"
      buyMessage: "&aYou have bought the &2<group>&a rank for &2$<mcost>!"
      signCreateMessage: "&aYou have created a promotion sign for rank &2<rank>&a with money cost &2$<mcost>&a and level requirement &2<lcost>!"
      withdrawErrorMessage: "&cSomething went wrong while trying to withdraw money."
      noPermissionMessage: "&cYou don't have permission to do this."
    

    Here's some information I should give you about the new permissions:
    • Attempting to create a promotion sign (by placing down a sign and writing at least the text defined in config on the first line) without the permission "signpromote.create" will clear the sign and cancel the event, thus not creating the promotion sign.
    • Attempting to use a promotion sign without the permission "signpromote.use" will cancel the event.
    I haven't done any "heavy" testing, however everything seems to work fine. I'd recommend you to test it on a test server first though.

    The plugin was compiled with PaperSpigot-443 for Minecraft 1.8.8, using dependencies:
    • mcMMO 1.4.08-b3544 for Minecraft 1.7.2 (because 1.8-1.9 versions were not working for me)
    • Vault 1.5.6-b49 for Minecraft 1.8.1
    • EssentialsGroupManager Pre2.14.1.3 FINAL (Phoenix) for I have no idea what Minecraft version :D
    I think this covers everything? Feel free to reply to this thread for any questions or issues, or private message me (assuming that even talking about a plugin in a private conversation is allowed @timtower).
     
    Last edited: Jun 27, 2016
  12. Offline

    M4son

    Dude, I can't describe with words how awesome you are. You are literally a hero! A HERO! Everything's working great! Thank you so much, I really really appreciate the staff you did, thanks again. Also, I hope you get well soon! :)
     
    Assist likes this.
  13. @M4son
    I'm glad it's working fine!
     
    M4son likes this.
Thread Status:
Not open for further replies.

Share This Page