diff options
author | ElgarL <ElgarL@palmergames.com> | 2011-09-21 12:30:11 +0100 |
---|---|---|
committer | ElgarL <ElgarL@palmergames.com> | 2011-09-21 12:30:11 +0100 |
commit | de744fe9e2d6e389b821dca5a3a9fab28d3be262 (patch) | |
tree | 82eb9bedcbf1a6f1a393a7cd9578a7fba6983d6b /EssentialsGroupManager/src/org | |
parent | 2bdc00dc143695f8b24c237bdee8389faf5ea0aa (diff) | |
download | Essentials-de744fe9e2d6e389b821dca5a3a9fab28d3be262.tar Essentials-de744fe9e2d6e389b821dca5a3a9fab28d3be262.tar.gz Essentials-de744fe9e2d6e389b821dca5a3a9fab28d3be262.tar.lz Essentials-de744fe9e2d6e389b821dca5a3a9fab28d3be262.tar.xz Essentials-de744fe9e2d6e389b821dca5a3a9fab28d3be262.zip |
- Reverted WorldHolder static change to maintain backward plugin
compatability.
Diffstat (limited to 'EssentialsGroupManager/src/org')
-rw-r--r-- | EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java | 6 | ||||
-rw-r--r-- | EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java | 8 |
2 files changed, 7 insertions, 7 deletions
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java index b48c3feae..b56d42122 100644 --- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java +++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java @@ -47,7 +47,7 @@ public class GroupManager extends JavaPlugin { private ScheduledThreadPoolExecutor scheduler; private Map<String, ArrayList<User>> overloadedUsers = new HashMap<String, ArrayList<User>>(); private Map<CommandSender, String> selectedWorlds = new HashMap<CommandSender, String>(); - private static WorldsHolder worldsHolder; + private WorldsHolder worldsHolder; private boolean validateOnlinePlayer = true; private boolean isReady = false; public static boolean isLoaded = false; @@ -123,7 +123,7 @@ public class GroupManager extends JavaPlugin { @Override public void run() { - GroupManager.worldsHolder.saveChanges(); + worldsHolder.saveChanges(); } }; scheduler = new ScheduledThreadPoolExecutor(1); @@ -166,7 +166,7 @@ public class GroupManager extends JavaPlugin { worldsHolder.reloadAll(); } - public static WorldsHolder getWorldsHolder() { + public WorldsHolder getWorldsHolder() { return worldsHolder; } diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java index ae22076a9..97695ffdb 100644 --- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java +++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java @@ -58,12 +58,12 @@ public class BukkitPermissions { protected Map<Player, PermissionAttachment> attachments = new HashMap<Player, PermissionAttachment>();
protected Set<Permission> registeredPermissions = new HashSet<Permission>();
- protected Plugin plugin;
+ protected GroupManager plugin;
protected boolean dumpAllPermissions = true;
protected boolean dumpMatchedPermissions = true;
public boolean player_join = false;
- public BukkitPermissions(Plugin plugin) {
+ public BukkitPermissions(GroupManager plugin) {
this.plugin = plugin;
this.collectPermissions();
@@ -120,7 +120,7 @@ public class BukkitPermissions { // All permissions registered with Bukkit for this player
PermissionAttachment attachment = this.attachments.get(player);
- OverloadedWorldHolder worldData = GroupManager.getWorldsHolder().getWorldData(world);
+ OverloadedWorldHolder worldData = plugin.getWorldsHolder().getWorldData(world);
User user = worldData.getUser(player.getName());
@@ -185,7 +185,7 @@ public class BukkitPermissions { player_join = true;
Player player = event.getPlayer();
//force GM to create the player if they are not already listed.
- if (GroupManager.getWorldsHolder().getWorldData(player.getWorld().getName()).getUser(player.getName()) != null) {
+ if (plugin.getWorldsHolder().getWorldData(player.getWorld().getName()).getUser(player.getName()) != null) {
player_join = false;
updatePermissions(event.getPlayer());
} else
|