summaryrefslogtreecommitdiffstats
path: root/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectWeatherListener.java
diff options
context:
space:
mode:
authorsnowleo <schneeleo@gmail.com>2012-01-20 05:20:37 +0100
committersnowleo <schneeleo@gmail.com>2012-01-20 05:20:37 +0100
commit792f70efa5f3a47f642360e97979fe841593384c (patch)
treebf119f53a3426f1016457d066820eb334eb393ac /EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectWeatherListener.java
parent46298ae85895574a097b1dd10c46196ffa1a42d3 (diff)
downloadEssentials-792f70efa5f3a47f642360e97979fe841593384c.tar
Essentials-792f70efa5f3a47f642360e97979fe841593384c.tar.gz
Essentials-792f70efa5f3a47f642360e97979fe841593384c.tar.lz
Essentials-792f70efa5f3a47f642360e97979fe841593384c.tar.xz
Essentials-792f70efa5f3a47f642360e97979fe841593384c.zip
Update for new CraftBukkit Event Code
EssentialsSpawn can't be updated yet, because the new event system lacks dynamic priorities.
Diffstat (limited to 'EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectWeatherListener.java')
-rw-r--r--EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectWeatherListener.java12
1 files changed, 7 insertions, 5 deletions
diff --git a/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectWeatherListener.java b/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectWeatherListener.java
index e81efc72b..1b8dd19ff 100644
--- a/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectWeatherListener.java
+++ b/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectWeatherListener.java
@@ -1,12 +1,14 @@
package com.earth2me.essentials.protect;
+import org.bukkit.event.EventHandler;
+import org.bukkit.event.EventPriority;
+import org.bukkit.event.Listener;
import org.bukkit.event.weather.LightningStrikeEvent;
import org.bukkit.event.weather.ThunderChangeEvent;
import org.bukkit.event.weather.WeatherChangeEvent;
-import org.bukkit.event.weather.WeatherListener;
-public class EssentialsProtectWeatherListener extends WeatherListener
+public class EssentialsProtectWeatherListener implements Listener
{
private final transient IProtect prot;
@@ -15,7 +17,7 @@ public class EssentialsProtectWeatherListener extends WeatherListener
this.prot = prot;
}
- @Override
+ @EventHandler(priority = EventPriority.HIGHEST)
public void onWeatherChange(final WeatherChangeEvent event)
{
if (!event.isCancelled()
@@ -27,7 +29,7 @@ public class EssentialsProtectWeatherListener extends WeatherListener
}
- @Override
+ @EventHandler(priority = EventPriority.HIGHEST)
public void onLightningStrike(final LightningStrikeEvent event)
{
if (!event.isCancelled()
@@ -37,7 +39,7 @@ public class EssentialsProtectWeatherListener extends WeatherListener
}
}
- @Override
+ @EventHandler(priority = EventPriority.HIGHEST)
public void onThunderChange(final ThunderChangeEvent event)
{
if (!event.isCancelled()