diff options
author | ElgarL <ElgarL@palmergames.com> | 2012-01-30 17:08:55 +0000 |
---|---|---|
committer | ElgarL <ElgarL@palmergames.com> | 2012-01-30 17:08:55 +0000 |
commit | fe050dd72591dc22a370ff4517bd30396fe36956 (patch) | |
tree | d6c8c23bab41e2394bc5670dc329d71dbdae2c55 /EssentialsGroupManager/src/org | |
parent | 5b4966c8883609b40dced835a0a38935df063f30 (diff) | |
download | Essentials-fe050dd72591dc22a370ff4517bd30396fe36956.tar Essentials-fe050dd72591dc22a370ff4517bd30396fe36956.tar.gz Essentials-fe050dd72591dc22a370ff4517bd30396fe36956.tar.lz Essentials-fe050dd72591dc22a370ff4517bd30396fe36956.tar.xz Essentials-fe050dd72591dc22a370ff4517bd30396fe36956.zip |
Track the 'onPlayerChangeWorld' event as some teleports seem to not be
triggering a world move.
Diffstat (limited to 'EssentialsGroupManager/src/org')
-rw-r--r-- | EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java index d1193510e..1409f774d 100644 --- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java +++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java @@ -34,6 +34,7 @@ import org.bukkit.entity.Player; import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
import org.bukkit.event.Listener;
+import org.bukkit.event.player.PlayerChangedWorldEvent;
import org.bukkit.event.player.PlayerJoinEvent;
import org.bukkit.event.player.PlayerKickEvent;
import org.bukkit.event.player.PlayerPortalEvent;
@@ -358,6 +359,11 @@ public class BukkitPermissions { }
setPlayer_join(false);
}
+
+ @EventHandler(priority = EventPriority.LOWEST)
+ public void onPlayerChangeWorld(PlayerChangedWorldEvent event) { // will portal into another world
+ updatePermissions(event.getPlayer(), event.getPlayer().getWorld().getName());
+ }
@EventHandler(priority = EventPriority.LOWEST)
public void onPlayerPortal(PlayerPortalEvent event) { // will portal into another world
|