Getting all permissions registered on the server

Discussion in 'Plugin Development' started by Googlelover1234, Jul 22, 2015.

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

    Googlelover1234

    Hey guys, I was working on a permissions plugin today, and noticed that if you add the permission '*' to the PermissionAttachment, it doesn't work like other permission plugins. I was in the mindset of the "wildcard" permission would give me all permissions, but I'm finding quite the opposite. Anyway, I have another plan, just to add all of the permissions registered to that player, but I am having trouble finding how to get them. So, basically what I'm asking is, how do you get all of the permissions currently registered on the server, in a string form that would give me all the nodes.
     
  2. Offline

    Zombie_Striker

    @Googlelover1234
    The '*' is coded into most plugins as an override. Bukkit does not do this on its own.

    If you wanted an example of how to do this:
    Code:
    if(Player#hasPermission("Permission.*") || Player#hasPermission("Permission.ThePermission") )
     
  3. Offline

    Googlelover1234

    @Zombie_Striker
    I was looking on actually getting the permissions from the server, as I did notice that the * thing wasn't working. Basically I wanted a way to get a List of all the permissions registered on the server, including other plugins.
     
  4. Offline

    Konato_K

Thread Status:
Not open for further replies.

Share This Page