Example #1
0
        public PermissionHandler(Interpreter interpreter)
        {
            interpreter
            .AddCommandLine("perm user <user> assign <role>")
            .SetDescription("Assign a role to a user")
            .SetAction(PermissionHandler.AssignRole);

            interpreter
            .AddCommandLine("perm user <user> unassign <role>")
            .SetDescription("Unassign a role from a user")
            .SetAction(PermissionHandler.UnAssignRole);;

            interpreter
            .AddCommandLine("perm role <role> canassign <role>")
            .SetDescription("Allow a role to assign another role")
            .SetAction(PermissionHandler.CanAssignRole);;
        }