diff options
author | snowleo <schneeleo@gmail.com> | 2012-01-24 00:52:08 +0100 |
---|---|---|
committer | snowleo <schneeleo@gmail.com> | 2012-01-24 00:52:08 +0100 |
commit | cc0e9aa84bc41e341f04202f1f0d2f3c402cf3f4 (patch) | |
tree | a7cbcd229b4a5c3dee2731b95b3ddc1ccd95df4c /EssentialsSigns | |
parent | 6af054631fe04ef7a607f24e459e37836c568100 (diff) | |
parent | f93769dd1dd11ef30c77dd6c9e0e5cf275052715 (diff) | |
download | Essentials-cc0e9aa84bc41e341f04202f1f0d2f3c402cf3f4.tar Essentials-cc0e9aa84bc41e341f04202f1f0d2f3c402cf3f4.tar.gz Essentials-cc0e9aa84bc41e341f04202f1f0d2f3c402cf3f4.tar.lz Essentials-cc0e9aa84bc41e341f04202f1f0d2f3c402cf3f4.tar.xz Essentials-cc0e9aa84bc41e341f04202f1f0d2f3c402cf3f4.zip |
Merge branch 'refs/heads/master' into 3.0
The changes to EssChat have not been merged
Conflicts:
Essentials/src/com/earth2me/essentials/Essentials.java
Essentials/src/com/earth2me/essentials/EssentialsEntityListener.java
Essentials/src/com/earth2me/essentials/ISettings.java
Essentials/src/com/earth2me/essentials/OfflinePlayer.java
Essentials/src/com/earth2me/essentials/Settings.java
Essentials/src/com/earth2me/essentials/Util.java
Essentials/src/com/earth2me/essentials/listener/EssentialsBlockListener.java
Essentials/src/com/earth2me/essentials/listener/EssentialsPlayerListener.java
Essentials/src/com/earth2me/essentials/listener/EssentialsPluginListener.java
Essentials/src/messages.properties
Essentials/src/messages_da.properties
Essentials/src/messages_de.properties
Essentials/src/messages_en.properties
Essentials/src/messages_es.properties
Essentials/src/messages_fr.properties
Essentials/src/messages_nl.properties
EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java
EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayer.java
EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerHighest.java
EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerLowest.java
EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerNormal.java
EssentialsGeoIP/src/com/earth2me/essentials/geoip/EssentialsGeoIP.java
EssentialsGeoIP/src/com/earth2me/essentials/geoip/EssentialsGeoIPPlayerListener.java
EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectBlockListener.java
EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectEntityListener.java
EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectPlayerListener.java
EssentialsSpawn/src/com/earth2me/essentials/spawn/EssentialsSpawn.java
EssentialsXMPP/src/com/earth2me/essentials/xmpp/EssentialsXMPP.java
EssentialsXMPP/src/com/earth2me/essentials/xmpp/EssentialsXMPPPlayerListener.java
Diffstat (limited to 'EssentialsSigns')
4 files changed, 32 insertions, 18 deletions
diff --git a/EssentialsSigns/src/com/earth2me/essentials/signs/EssentialsSignsPlugin.java b/EssentialsSigns/src/com/earth2me/essentials/signs/EssentialsSignsPlugin.java index fd14eba0e..d57daf319 100644 --- a/EssentialsSigns/src/com/earth2me/essentials/signs/EssentialsSignsPlugin.java +++ b/EssentialsSigns/src/com/earth2me/essentials/signs/EssentialsSignsPlugin.java @@ -44,7 +44,14 @@ public class EssentialsSignsPlugin extends JavaPlugin final SignEntityListener signEntityListener = new SignEntityListener(ess); pluginManager.registerEvent(Event.Type.ENTITY_EXPLODE, signEntityListener, Event.Priority.Low, this); pluginManager.registerEvent(Event.Type.ENDERMAN_PICKUP, signEntityListener, Event.Priority.Low, this); + //final SignBlockListener signBlockListener = new SignBlockListener(ess); + pluginManager.registerEvents(signBlockListener, this); + //final SignPlayerListener signPlayerListener = new SignPlayerListener(ess); + pluginManager.registerEvents(signPlayerListener, this); + + //final SignEntityListener signEntityListener = new SignEntityListener(ess); + pluginManager.registerEvents(signEntityListener, this); LOGGER.info(_("loadinfo", this.getDescription().getName(), this.getDescription().getVersion(), "essentials team")); } diff --git a/EssentialsSigns/src/com/earth2me/essentials/signs/SignBlockListener.java b/EssentialsSigns/src/com/earth2me/essentials/signs/SignBlockListener.java index 7cc461782..a072cd038 100644 --- a/EssentialsSigns/src/com/earth2me/essentials/signs/SignBlockListener.java +++ b/EssentialsSigns/src/com/earth2me/essentials/signs/SignBlockListener.java @@ -8,10 +8,13 @@ import org.bukkit.Material; import org.bukkit.block.Block; import org.bukkit.block.Sign; import org.bukkit.entity.Player; +import org.bukkit.event.EventHandler; +import org.bukkit.event.EventPriority; +import org.bukkit.event.Listener; import org.bukkit.event.block.*; -public class SignBlockListener extends BlockListener +public class SignBlockListener implements Listener { private final transient IEssentials ess; private final static Logger LOGGER = Logger.getLogger("Minecraft"); @@ -21,7 +24,7 @@ public class SignBlockListener extends BlockListener this.ess = ess; } - @Override + @EventHandler(priority = EventPriority.HIGHEST) public void onBlockBreak(final BlockBreakEvent event) { if (event.isCancelled()) @@ -73,7 +76,7 @@ public class SignBlockListener extends BlockListener return false; } - @Override + @EventHandler(priority = EventPriority.HIGHEST) public void onSignChange(final SignChangeEvent event) { if (event.isCancelled()) @@ -105,7 +108,7 @@ public class SignBlockListener extends BlockListener } } - @Override + @EventHandler(priority = EventPriority.LOW) public void onBlockPlace(final BlockPlaceEvent event) { if (event.isCancelled()) @@ -139,7 +142,7 @@ public class SignBlockListener extends BlockListener } } - @Override + @EventHandler(priority = EventPriority.LOW) public void onBlockBurn(final BlockBurnEvent event) { if (event.isCancelled()) @@ -168,7 +171,7 @@ public class SignBlockListener extends BlockListener } } - @Override + @EventHandler(priority = EventPriority.LOW) public void onBlockIgnite(final BlockIgniteEvent event) { if (event.isCancelled()) @@ -197,7 +200,7 @@ public class SignBlockListener extends BlockListener } } - @Override + @EventHandler(priority = EventPriority.LOW) public void onBlockPistonExtend(final BlockPistonExtendEvent event) { for (Block block : event.getBlocks()) @@ -223,7 +226,7 @@ public class SignBlockListener extends BlockListener } } - @Override + @EventHandler(priority = EventPriority.LOW) public void onBlockPistonRetract(final BlockPistonRetractEvent event) { if (event.isSticky()) diff --git a/EssentialsSigns/src/com/earth2me/essentials/signs/SignEntityListener.java b/EssentialsSigns/src/com/earth2me/essentials/signs/SignEntityListener.java index 12a2fc2f8..2d3413559 100644 --- a/EssentialsSigns/src/com/earth2me/essentials/signs/SignEntityListener.java +++ b/EssentialsSigns/src/com/earth2me/essentials/signs/SignEntityListener.java @@ -3,12 +3,14 @@ package com.earth2me.essentials.signs; import com.earth2me.essentials.api.IEssentials; import org.bukkit.Material; import org.bukkit.block.Block; +import org.bukkit.event.EventHandler; +import org.bukkit.event.EventPriority; +import org.bukkit.event.Listener; import org.bukkit.event.entity.EndermanPickupEvent; import org.bukkit.event.entity.EntityExplodeEvent; -import org.bukkit.event.entity.EntityListener; -public class SignEntityListener extends EntityListener +public class SignEntityListener implements Listener { private final transient IEssentials ess; @@ -17,7 +19,7 @@ public class SignEntityListener extends EntityListener this.ess = ess; } - @Override + @EventHandler(priority = EventPriority.LOW) public void onEntityExplode(final EntityExplodeEvent event) { for (Block block : event.blockList()) @@ -42,8 +44,8 @@ public class SignEntityListener extends EntityListener } } - @Override - public void onEndermanPickup(EndermanPickupEvent event) + @EventHandler(priority = EventPriority.LOW) + public void onEndermanPickup(final EndermanPickupEvent event) { if (event.isCancelled()) { diff --git a/EssentialsSigns/src/com/earth2me/essentials/signs/SignPlayerListener.java b/EssentialsSigns/src/com/earth2me/essentials/signs/SignPlayerListener.java index 9f1a22896..dd2219ef8 100644 --- a/EssentialsSigns/src/com/earth2me/essentials/signs/SignPlayerListener.java +++ b/EssentialsSigns/src/com/earth2me/essentials/signs/SignPlayerListener.java @@ -4,22 +4,24 @@ import com.earth2me.essentials.api.IEssentials; import org.bukkit.Material; import org.bukkit.block.Block; import org.bukkit.block.Sign; +import org.bukkit.event.EventHandler; +import org.bukkit.event.EventPriority; +import org.bukkit.event.Listener; import org.bukkit.event.block.Action; import org.bukkit.event.player.PlayerInteractEvent; -import org.bukkit.event.player.PlayerListener; -public class SignPlayerListener extends PlayerListener +public class SignPlayerListener implements Listener { private final transient IEssentials ess; - public SignPlayerListener(IEssentials ess) + public SignPlayerListener(final IEssentials ess) { this.ess = ess; } - @Override - public void onPlayerInteract(PlayerInteractEvent event) + @EventHandler(priority = EventPriority.LOW) + public void onPlayerInteract(final PlayerInteractEvent event) { if (event.isCancelled()) { |