Permissions FAQ

Discussion in 'Plugin Development' started by Dinnerbone, Jul 7, 2011.

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

    Bobfan

    Some people have their opinions.
     
  2. Offline

    evilmidget38

    I agree. Some people also shouldn't be running a server, especially if they're incapable of doing permissions.
     
    ferrybig likes this.
  3. Offline

    0megadoom

    Alright. First post ever. Never had to before but i am having a bit of an issue upgrading to 2.0

    i was running 1.6 and the case sensitive problem was causing me to have major crashes all the time when trying to promote my friend. initially i was able to promote, but that stopped working and just causes the server to crash now. now i put a lot of efforts into my config.yml and i do not by any means want to rewrite it all. so i did what any smart person would do and made a backup, then upgraded, deleted the 2.0 config.yml and replaced it with mine. i go on the console and do the whole "permissions player setgroup yadda yadda" and it says it works. However he loses all previous build rights and plugin access, and my config.yml goes blank and only has:

    Groups:

    Player:
    name
    -somerank

    and everything goes all to hell.... any suggestions?
     
  4. Offline

    firelord043

    Dinner bone can I have some help doing that for basic stuff like essentials because when I tried it didn't work.
     
  5. Offline

    CubieX

    Is there a way to check if there is a Superperms compatible plugin for managing permissions present?

    Currently I'm doing this:
    Code:
    private boolean hookToPermissionSystem()
    {
    if (getServer().getPluginManager().getPlugin("PermissionsEx") == null)
    {
    return false;
    }
    else
    {
    return true;
    }
    }
    But actually I dont't want to limit this to PEX.
    I just want to now, wether or not a proper permissions plugin is present, that supports superperms.
     
  6. scan first al known not super perm plugins, then use superperm as fallback, so use superperm if no alternative is found, as superperm wont give errors when there is no handling plugin is installed
     
  7. Offline

    brixazure

    okay im lost at how to make permissions that work for my server,, this is what i wrote in

    "users:
    brixazure:
    permissions:
    tardis.adm: true
    tardis.skeletonkey: true
    permissions.build: true
    tardis.use: true
    tardis.bigger: true
    tardis.deluxe: true
    groups:
    - user
    groups:
    default:
    permissions:
    permissions.build: true
    tardis.adm: true
    tardis.skeletonkey: true
    permissions.build: true
    tardis.use: true
    tardis.bigger: true
    tardis.deluxe: true
    creative: false
    admin:
    permissions:
    permissions.*: true
    tardis.adm: true
    tardis.skeletonkey: true
    permissions.build: true
    tardis.use: true
    tardis.bigger: true
    tardis.deluxe: true
    inheritance:
    - user
    user:
    permissions:
    tardis.adm: true
    tardis.skeletonkey: true
    permissions.build: true
    tardis.use: true
    tardis.bigger: true
    tardis.deluxe: true
    creative: false
    worlds:
    creative:
    coolplugin.item: true
    inheritance:
    - default
    messages:
    build: '&cYou do not have permission to build here.'

    debug: false"

    none of these seem to load, and brix isnt an OP so im trying to use this so players can use addons.

    and i need to add the SimepleRedstone Teleport, to the permissions.
    any help would be great.

    Brixazure
     
  8. Offline

    SplotchyJester2

    My permissions arent working, it acts as if they are not there. The plugin and permissions are correct its just the players dont get the permissions. Check if you can see an error:
    Code:
    # PermissionsBukkit configuration file
    #
    # A permission node is a string like 'permissions.build', usually starting
    # with the name of the plugin. Refer to a plugin's documentation for what
    # permissions it cares about. Each node should be followed by true to grant
    # that permission or false to revoke it, as in 'permissions.build: true'.
    # Some plugins provide permission nodes that map to a group of permissions -
    # for example, PermissionsBukkit has 'permissions.*', which automatically
    # grants all admin permissions. You can also specify false for permissions
    # of this type.
    #
    # Users inherit permissions from the groups they are a part of. If a user is
    # not specified here, or does not have a 'groups' node, they will be in the
    # group 'default'. Permissions for individual users may also be specified by
    # using a 'permissions' node with a list of permission nodes, which will
    # override their group permissions. World permissions may be assigned to
    # users with a 'worlds:' entry.
    #
    # Groups can be assigned to players and all their permissions will also be
    # assigned to those players. Groups can also inherit permissions from other
    # groups. Like user permissions, groups may override the permissions of their
    # parent group(s). Unlike users, groups do NOT automatically inherit from
    # default. World permissions may be assigned to groups with a 'worlds:' entry.
    #
    # The cannot-build message is configurable. If it is left blank, no message
    # will be displayed to the player if PermissionsBukkit prevents them from
    # building, digging, or interacting with a block. Use '&' characters to
    # signify color codes.
     
    users:
        SplotchyJester2:
            permissions:
                '*': true
                permissions.*: true
            groups:
            - Owner
        Jbull22:
            permissions: []
            groups:
            - Moderator
    groups:
        default:
            permissions:
                permissions.build: true
                essentials.kit: true
                essentials.balance: true
                essentials.pay: true
                essentials.sell: true
                essentials.worth: true
                essentials.afk: true
                essentials.afk.auto: true
                essentials.getpos: true
                essentials.help: true
                essentials.helpop: true
                essentials.ignore: true
                essentials.itemdb: true
                essentials.list: true
                essentials.mail: true
                essentials.mail.send: true
                essentials.motd: true
                essentials.msg: true
                essentialsrealname: true
                essentials.rules: true
                essentials.seen: true
                essentials.seen.banreason: true
                essentials.suiside: true
                essentials.mute: true
                essentials.ping: true
                essentials.spawn: true
                essentials.delhome: true
                essentials.home: true
                essentials.sethome: true
                essentails.tpa: true
                essentials.tpaccept: true
                essentials.tpahere: true
                essentials.tpdeny: true
                essentials.signs.use.*: true
                simpleprefix.member: true
                essentials.workbench: true
                essentials.afk.kickexempt: true
                essentials.afk.auto: true
                essentials.afk: true
                essentials.motd.true
                essentials.helpop: true
                essentials.msg: true
                essentials.clearinventory: true
                essentals.suiside: true
                essentials.signs.use.*: true
        Moderator:
            permissions:
                essentials.fly: true
                essentials.fly.safelogin: true
                essentials.god: true
                essentials.kit.others: true
                essentials.speed: true
                essentials.balance.others: true
                essentials.afk: true
                essentialsafk.others: true
                essentials.chat.ignoreexempt: true
                essentials.helpop.recieve: true
                essentials.invsee: true
                essentials.kick: true
                essentials.kick.exempt: true
                essentials.mute.exempt: true
                essentials.socialspy: true
                essentials.tp: true
                essentials.tp.others: true
                essentials.tphere: true
                simpleprefix.moderator: true
                essentials.whois: true
                essentials.seen: true
                essentials.list: true
            inheritance:
                - default
        SuperModerator:
                essentials.time: true
                essentials.time.set: true
                essentials.tempban: true
                essentials.ban: true
                essentials.seen.banreason: true
                essentials.unban: true
                simpleprefix.Supermoderator: true
            inheritance:
                - moderator
        Owner:
            permissions:
                permissions.*: true
                simpleprefix.owner: true
            inheritance:
            - Admin
    messages:
        build: '&cYou do not have permission to build here.'
     
    debug: false
     
  9. Offline

    kreashenz

    SplotchyJester2 You're not doing it correctly. You're doing it like the plugin.yml which is incorrect for this.
    Code:
    users:
        SplotchyJester2:
            permissions:
                - '*'
                - permissions.*
            groups:
            - Owner
        Jbull22:
            permissions: []
            groups:
            - Moderator
    Try using lists, like how I've done it.
     
  10. Offline

    SplotchyJester2

    Are the list just for the users or for the permissions too?

    Ok wait now my ranks are fixed, yet another problem is showing up now, the ranks arent getting the proper permissions, every rank doesnt have permissions to anything see if you see the error kreashenz or anyone else who is good with this:

    Code:
    users:
      SplotchyJester2:
        permissions:
        - '*': true
        - permissions.*: true
        groups:
        - Owner
      Jbull22:
        permissions: []
        groups:
        - Moderator
      saintcaulin:
        groups:
        - default
    groups:
      default:
        default: true
        build: true
        permissions:
        - essentials.kit: true
        - essentials.balance: true
        - essentials.pay: true
        - essentials.sell: true
        - essentials.worth: true
        - essentials.afk: true
        - essentials.afk.auto: true
        - essentials.getpos: true
        - essentials.help: true
        - essentials.helpop: true
        - essentials.ignore: true
        - essentials.itemdb: true
        - essentials.list: true
        - essentials.mail: true
        - essentials.mail.send: true
        - essentials.motd: true
        - essentials.msg: true
        - essentials.realname: true
        - essentials.rules: true
        - essentials.seen: true
        - essentials.seen.banreason: true
        - essentials.suiside: true
        - essentials.ping: true
        - essentials.spawn: true
        - essentials.delhome: true
        - essentials.home: true
        - essentials.sethome: true
        - essentails.tpa: true
        - essentials.tpaccept: true
        - essentials.tpahere: true
        - essentials.tpdeny: true
        - essentials.signs.use.*: true
        - simpleprefix.defualt: true
        - essentials.workbench: true
        - essentials.afk.kickexempt: true
        - essentials.afk.auto: true
        - essentials.afk: true
        - essentials.motd.true
        - essentials.helpop: true
        - essentials.msg: true
        - essentials.clearinventory: true
        - essentals.suiside: true
        - essentials.signs.use.*: true
      Moderator:
        build: true
        permissions:
        - essentials.fly: true
        - essentials.fly.safelogin: true
        - essentials.god: true
        - essentials.kit.others: true
        - essentials.speed: true
        - essentials.balance.others: true
        - essentials.afk: true
        - essentialsafk.others: true
        - essentials.chat.ignoreexempt: true
        - essentials.helpop.recieve: true
        - essentials.invsee: true
        - essentials.kick: true
        - essentials.kick.exempt: true
        - essentials.mute.exempt: true
        - essentials.socialspy: true
        - essentials.tp: true
        - essentials.tp.others: true
        - essentials.tphere: true
        - simpleprefix.moderator: true
        - essentials.whois: true
        - essentials.seen: true
        - essentials.list: true
        inheritance:
        - default
      SuperModerator:
        build: true
        permissions:
        - essentials.time: true
        - essentials.time.set: true
        - essentials.tempban: true
        - essentials.ban: true
        - essentials.seen.banreason: true
        - essentials.unban: true
        - simpleprefix.Supermoderator: true
        inheritance:
        - moderator
      Owner:
        build: true
        permissions:
        - permissions.*: true
        - simpleprefix.owner: true
        inheritance:
        - Admin
    messages:
      build: '&cYou do not have permission to build here.'
    debug: false
    Is the spacing wrong because when i fixed it it completely changed the spacing?

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 17, 2016
  11. Offline

    pookeythekid


    if (player.hasPermission("teleport.use") || player.isOp()) {
    // whatever your teleporting system is here
    } else if (!(player.hasPermission("teleport.use")) {
    player.sendMessage(ChatColor.DARK_RED + "You do not have permission to perform this command!");
    }

    In Java, the ! symbol means "does not" or "don't do this", pretty much cancellation or something negative.

    How would you make per-warp permissions or something? For example, you use the command "/setmywarp thiswarp" and then there's the ability to deny the permission to use that warp. To deny that warp, you would deny the permission "mywarps.warps.thiswarp".

    I've been told before to use a command executor to register the permission on command, but I can't think at all how the heck that could be done! Please help, I've been searching for the answer to this for over a month.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 17, 2016
  12. Offline

    MordorKing78

    For plugin developers:
    All of that.. If u didnt know that plz stop coding ;)
     
  13. Offline

    pookeythekid

    MordorKing78
    Erm, if that was directed at me... *gasp* Rude! By now I've figured it out, and I suppose it's because I kept coding. >:I
     
  14. Offline

    MordorKing78

    pookeythekid Haha, I think i was frustraded! Just keep coding! Bukkit is for help!
     
  15. Offline

    pookeythekid

  16. Offline

    Sinntax

    wow. what a read! I couldn't get through it all... is there a FAQ or Guide somewhere to help convert from 'Group Manager' ????
     
  17. Offline

    Necrodoom

    Switch to what? It already uses the permissions API, so is every other permission plugin.
     
  18. Offline

    Sinntax

    So, Groupmanager is OK? I don't need to switch to PEX or just use the perrmisions file in the main directory?

    /confused

    my DragonTravel and MobBountyReloaded don't work, was under the impression it might be GM
     
  19. Offline

    Necrodoom

    Sinntax no, you don't need to replace anything. For your plugin problems, make a thread at bukkit help describing your issue.
     
Thread Status:
Not open for further replies.

Share This Page