Permission Variables

1.7-alpha or newer required for this feature.

What is Permission Variable?

Variables for Permission is a way to more flexibly customize permissions for your plugin.

They can help you setup more complex permissions without making more permissions for 1 player.

How to use it

Let's get started with the preparation. To use Permission variables, you need to tell the method where your variable is located. To use Permission variables, you need to put a label on the line to indicate where your variable is located.

For example: tailslib.permissionexample.%var%.other

The %var% label indicates where the variable we are working with is located. Then we just need to call one of the methods and get our variable.

// Player contain tailslib.permissionexample.6.other permission.
PermissionVariables.getIntPermissionVariable(player, 
        "tailslib.permissionexample.%var%.other"); // Output: 6

How to give permission to player?

Use LuckyPerms (or something like this) plugin.

Just give your permission to player and replace %var% with actual variable.

For example: tailslib.permissionexample.123.other, tailslib.permissionexample.helloworld.other, tailslib.permissionexample.yes.other, tailslib.permissionexample.false.other,

For boolean variables you can use yes or no statement (or true/false)

Last updated