Add Sponge permissions for 1.11.2, 1.12.2, extract
permissions.yml.example
This commit is contained in:
parent
24b2a00d23
commit
2718feb137
9 changed files with 106 additions and 4 deletions
|
|
@ -1475,9 +1475,9 @@ public class DynmapPlugin
|
|||
/* Set up player login/quit event handler */
|
||||
registerPlayerLoginListener();
|
||||
/* Initialize permissions handler */
|
||||
permissions = Sponge7Permissions.create();
|
||||
permissions = FilePermissions.create();
|
||||
if (permissions == null) {
|
||||
permissions = FilePermissions.create();
|
||||
permissions = Sponge7Permissions.create();
|
||||
}
|
||||
if(permissions == null) {
|
||||
permissions = new OpPermissions(new String[] { "webchat", "marker.icons", "marker.list", "webregister", "stats", "hide.self", "show.self" });
|
||||
|
|
@ -1510,6 +1510,10 @@ public class DynmapPlugin
|
|||
{
|
||||
return;
|
||||
}
|
||||
// Extract default permission example, if needed
|
||||
File filepermexample = new File(core.getDataFolder(), "permissions.yml.example");
|
||||
core.createDefaultFileFromResource("/permissions.yml.example", filepermexample);
|
||||
|
||||
DynmapCommonAPIListener.apiInitialized(core);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@ public class Sponge7Permissions implements PermissionProvider {
|
|||
}
|
||||
Log.info("Using Sponge Permissions for access control");
|
||||
Log.info("Web interface permissions only available for online users");
|
||||
Log.info("Note: you may need to give users permissions for base commands (e.g. dynmap.command.* on LuckPerms) as well as for specific actions");
|
||||
return new Sponge7Permissions();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue