mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-11-16 17:16:11 +00:00
Load Bukkit plugin at startup.
This should allow plugins that use WorldEdit to do things on world load.
This commit is contained in:
parent
9d2d43f0db
commit
c885f70c7b
@ -35,6 +35,9 @@ public class VaultResolver implements PermissionsResolver {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
RegisteredServiceProvider<Permission> rsp = server.getServicesManager().getRegistration(Permission.class);
|
RegisteredServiceProvider<Permission> rsp = server.getServicesManager().getRegistration(Permission.class);
|
||||||
|
if (rsp == null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
perms = rsp.getProvider();
|
perms = rsp.getProvider();
|
||||||
if (perms == null) {
|
if (perms == null) {
|
||||||
return null;
|
return null;
|
||||||
|
@ -86,13 +86,9 @@ public class WorldEditPlugin extends JavaPlugin implements TabCompleter {
|
|||||||
private BukkitServerInterface server;
|
private BukkitServerInterface server;
|
||||||
private BukkitConfiguration config;
|
private BukkitConfiguration config;
|
||||||
|
|
||||||
/**
|
|
||||||
* Called on plugin enable.
|
|
||||||
*/
|
|
||||||
@SuppressWarnings("AccessStaticViaInstance")
|
|
||||||
@Override
|
@Override
|
||||||
public void onEnable() {
|
public void onLoad() {
|
||||||
this.INSTANCE = this;
|
INSTANCE = this;
|
||||||
|
|
||||||
//noinspection ResultOfMethodCallIgnored
|
//noinspection ResultOfMethodCallIgnored
|
||||||
getDataFolder().mkdirs();
|
getDataFolder().mkdirs();
|
||||||
@ -107,6 +103,13 @@ public class WorldEditPlugin extends JavaPlugin implements TabCompleter {
|
|||||||
worldEdit.loadMappings();
|
worldEdit.loadMappings();
|
||||||
|
|
||||||
loadConfig(); // Load configuration
|
loadConfig(); // Load configuration
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called on plugin enable.
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void onEnable() {
|
||||||
PermissionsResolverManager.initialize(this); // Setup permission resolver
|
PermissionsResolverManager.initialize(this); // Setup permission resolver
|
||||||
|
|
||||||
// Register CUI
|
// Register CUI
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
name: WorldEdit
|
name: WorldEdit
|
||||||
main: com.sk89q.worldedit.bukkit.WorldEditPlugin
|
main: com.sk89q.worldedit.bukkit.WorldEditPlugin
|
||||||
version: "${internalVersion}"
|
version: "${internalVersion}"
|
||||||
softdepend: [Spout] #hack to fix trove errors
|
load: STARTUP
|
||||||
api-version: 1.13
|
api-version: 1.13
|
||||||
|
|
||||||
# Permissions aren't here. Read http://wiki.sk89q.com/wiki/WEPIF/DinnerPerms
|
# Permissions aren't here. Read http://wiki.sk89q.com/wiki/WEPIF/DinnerPerms
|
||||||
|
Loading…
Reference in New Issue
Block a user