mirror of
https://github.com/taoneill/war.git
synced 2024-11-23 18:55:28 +01:00
Updated pom to Bukkit 1.1-R1, which broke the Events API again. Guess they never heard of backward compatibility. Oh well.
This commit is contained in:
parent
13067f35ad
commit
668285ac97
@ -56,13 +56,13 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.bukkit</groupId>
|
<groupId>org.bukkit</groupId>
|
||||||
<artifactId>bukkit</artifactId>
|
<artifactId>bukkit</artifactId>
|
||||||
<version>1.1-R1-SNAPSHOT</version>
|
<version>1.1-R1</version>
|
||||||
<scope>compile</scope>
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.bukkit</groupId>
|
<groupId>org.bukkit</groupId>
|
||||||
<artifactId>craftbukkit</artifactId>
|
<artifactId>craftbukkit</artifactId>
|
||||||
<version>1.1-R1-SNAPSHOT</version>
|
<version>1.1-R1</version>
|
||||||
<scope>compile</scope>
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -40,7 +40,7 @@ public class WarBlockListener implements Listener {
|
|||||||
/**
|
/**
|
||||||
* @see BlockListener.onBlockPlace()
|
* @see BlockListener.onBlockPlace()
|
||||||
*/
|
*/
|
||||||
@EventHandler(event = BlockPlaceEvent.class)
|
@EventHandler
|
||||||
public void onBlockPlace(final BlockPlaceEvent event) {
|
public void onBlockPlace(final BlockPlaceEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
@ -164,7 +164,7 @@ public class WarBlockListener implements Listener {
|
|||||||
event.getPlayer().setItemInHand(newItemInHand);
|
event.getPlayer().setItemInHand(newItemInHand);
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = BlockPistonExtendEvent.class)
|
@EventHandler
|
||||||
// Do not allow moving of block into or from important zones
|
// Do not allow moving of block into or from important zones
|
||||||
public void onBlockPistonExtend(final BlockPistonExtendEvent event) {
|
public void onBlockPistonExtend(final BlockPistonExtendEvent event) {
|
||||||
Warzone zone = Warzone.getZoneByLocation(event.getBlock().getLocation());
|
Warzone zone = Warzone.getZoneByLocation(event.getBlock().getLocation());
|
||||||
@ -182,7 +182,7 @@ public class WarBlockListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = BlockPistonRetractEvent.class)
|
@EventHandler
|
||||||
public void onBlockPistonRetract(final BlockPistonRetractEvent event) {
|
public void onBlockPistonRetract(final BlockPistonRetractEvent event) {
|
||||||
Warzone zone = Warzone.getZoneByLocation(event.getBlock().getLocation());
|
Warzone zone = Warzone.getZoneByLocation(event.getBlock().getLocation());
|
||||||
if (zone!=null) {
|
if (zone!=null) {
|
||||||
@ -197,7 +197,7 @@ public class WarBlockListener implements Listener {
|
|||||||
/**
|
/**
|
||||||
* @see BlockListener.onBlockBreak()
|
* @see BlockListener.onBlockBreak()
|
||||||
*/
|
*/
|
||||||
@EventHandler(event = BlockBreakEvent.class)
|
@EventHandler
|
||||||
public void onBlockBreak(final BlockBreakEvent event) {
|
public void onBlockBreak(final BlockBreakEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
@ -209,7 +209,7 @@ public class WarBlockListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = BlockDamageEvent.class)
|
@EventHandler
|
||||||
public void onBlockDamage(final BlockDamageEvent event) {
|
public void onBlockDamage(final BlockDamageEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
|
@ -291,7 +291,7 @@ public class WarEntityListener implements Listener {
|
|||||||
*
|
*
|
||||||
* @see EntityListener.onEntityExplode()
|
* @see EntityListener.onEntityExplode()
|
||||||
*/
|
*/
|
||||||
@EventHandler(event = EntityExplodeEvent.class)
|
@EventHandler
|
||||||
public void onEntityExplode(final EntityExplodeEvent event) {
|
public void onEntityExplode(final EntityExplodeEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
@ -406,7 +406,7 @@ public class WarEntityListener implements Listener {
|
|||||||
*
|
*
|
||||||
* @see EntityListener.onEntityDamage()
|
* @see EntityListener.onEntityDamage()
|
||||||
*/
|
*/
|
||||||
@EventHandler(event = EntityDamageEvent.class)
|
@EventHandler
|
||||||
public void onEntityDamage(final EntityDamageEvent event) {
|
public void onEntityDamage(final EntityDamageEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
@ -467,7 +467,7 @@ public class WarEntityListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = EntityDamageEvent.class)
|
@EventHandler
|
||||||
public void onEntityCombust(final EntityDamageEvent event) {
|
public void onEntityCombust(final EntityDamageEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
@ -493,7 +493,7 @@ public class WarEntityListener implements Listener {
|
|||||||
*
|
*
|
||||||
* @see EntityListener.onCreatureSpawn()
|
* @see EntityListener.onCreatureSpawn()
|
||||||
*/
|
*/
|
||||||
@EventHandler(event = CreatureSpawnEvent.class)
|
@EventHandler
|
||||||
public void onCreatureSpawn(final CreatureSpawnEvent event) {
|
public void onCreatureSpawn(final CreatureSpawnEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
@ -511,7 +511,7 @@ public class WarEntityListener implements Listener {
|
|||||||
*
|
*
|
||||||
* @see EntityListener.onEntityRegainHealth()
|
* @see EntityListener.onEntityRegainHealth()
|
||||||
*/
|
*/
|
||||||
@EventHandler(event = EntityRegainHealthEvent.class)
|
@EventHandler
|
||||||
public void onEntityRegainHealth(final EntityRegainHealthEvent event) {
|
public void onEntityRegainHealth(final EntityRegainHealthEvent event) {
|
||||||
if (!War.war.isLoaded() ||
|
if (!War.war.isLoaded() ||
|
||||||
(event.getRegainReason() != RegainReason.REGEN
|
(event.getRegainReason() != RegainReason.REGEN
|
||||||
@ -541,7 +541,7 @@ public class WarEntityListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = FoodLevelChangeEvent.class)
|
@EventHandler
|
||||||
public void onFoodLevelChange(final FoodLevelChangeEvent event) {
|
public void onFoodLevelChange(final FoodLevelChangeEvent event) {
|
||||||
if (!War.war.isLoaded() || !(event.getEntity() instanceof Player)) {
|
if (!War.war.isLoaded() || !(event.getEntity() instanceof Player)) {
|
||||||
return;
|
return;
|
||||||
@ -555,7 +555,7 @@ public class WarEntityListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = EntityDeathEvent.class)
|
@EventHandler
|
||||||
public void onEntityDeath(final EntityDeathEvent event) {
|
public void onEntityDeath(final EntityDeathEvent event) {
|
||||||
if (!War.war.isLoaded() || !(event.getEntity() instanceof Player)) {
|
if (!War.war.isLoaded() || !(event.getEntity() instanceof Player)) {
|
||||||
return;
|
return;
|
||||||
@ -578,7 +578,7 @@ public class WarEntityListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = ExplosionPrimeEvent.class)
|
@EventHandler
|
||||||
public void onExplosionPrime(final ExplosionPrimeEvent event) {
|
public void onExplosionPrime(final ExplosionPrimeEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
|
@ -59,7 +59,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
*
|
*
|
||||||
* @see PlayerListener.onPlayerQuit()
|
* @see PlayerListener.onPlayerQuit()
|
||||||
*/
|
*/
|
||||||
@EventHandler(event = PlayerQuitEvent.class)
|
@EventHandler
|
||||||
public void onPlayerQuit(final PlayerQuitEvent event) {
|
public void onPlayerQuit(final PlayerQuitEvent event) {
|
||||||
if (War.war.isLoaded()) {
|
if (War.war.isLoaded()) {
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
@ -74,7 +74,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerDropItemEvent.class)
|
@EventHandler
|
||||||
public void onPlayerDropItem(final PlayerDropItemEvent event) {
|
public void onPlayerDropItem(final PlayerDropItemEvent event) {
|
||||||
if (War.war.isLoaded()) {
|
if (War.war.isLoaded()) {
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
@ -136,7 +136,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerPickupItemEvent.class)
|
@EventHandler
|
||||||
public void onPlayerPickupItem(final PlayerPickupItemEvent event) {
|
public void onPlayerPickupItem(final PlayerPickupItemEvent event) {
|
||||||
if (War.war.isLoaded()) {
|
if (War.war.isLoaded()) {
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
@ -165,7 +165,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerInventoryEvent.class)
|
@EventHandler
|
||||||
public void onInventoryOpen(final PlayerInventoryEvent event) {
|
public void onInventoryOpen(final PlayerInventoryEvent event) {
|
||||||
if (War.war.isLoaded()) {
|
if (War.war.isLoaded()) {
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
@ -185,7 +185,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerCommandPreprocessEvent.class)
|
@EventHandler
|
||||||
public void onPlayerCommandPreprocess(final PlayerCommandPreprocessEvent event) {
|
public void onPlayerCommandPreprocess(final PlayerCommandPreprocessEvent event) {
|
||||||
if (War.war.isLoaded()) {
|
if (War.war.isLoaded()) {
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
@ -211,7 +211,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerKickEvent.class)
|
@EventHandler
|
||||||
public void onPlayerKick(final PlayerKickEvent event) {
|
public void onPlayerKick(final PlayerKickEvent event) {
|
||||||
if (War.war.isLoaded()) {
|
if (War.war.isLoaded()) {
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
@ -231,7 +231,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerInteractEvent.class)
|
@EventHandler
|
||||||
public void onPlayerInteract(PlayerInteractEvent event) {
|
public void onPlayerInteract(PlayerInteractEvent event) {
|
||||||
if (War.war.isLoaded()) {
|
if (War.war.isLoaded()) {
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
@ -268,7 +268,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerMoveEvent.class)
|
@EventHandler
|
||||||
public void onPlayerMove(final PlayerMoveEvent event) {
|
public void onPlayerMove(final PlayerMoveEvent event) {
|
||||||
if (!War.war.isLoaded()) {
|
if (!War.war.isLoaded()) {
|
||||||
return;
|
return;
|
||||||
@ -739,7 +739,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerToggleSneakEvent.class)
|
@EventHandler
|
||||||
public void onPlayerToggleSneak(PlayerToggleSneakEvent event) {
|
public void onPlayerToggleSneak(PlayerToggleSneakEvent event) {
|
||||||
if (War.war.isLoaded() && event.isSneaking()) {
|
if (War.war.isLoaded() && event.isSneaking()) {
|
||||||
Warzone playerWarzone = Warzone.getZoneByLocation(event.getPlayer());
|
Warzone playerWarzone = Warzone.getZoneByLocation(event.getPlayer());
|
||||||
@ -759,7 +759,7 @@ public class WarPlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(event = PlayerRespawnEvent.class)
|
@EventHandler
|
||||||
public void onPlayerRespawn(PlayerRespawnEvent event) {
|
public void onPlayerRespawn(PlayerRespawnEvent event) {
|
||||||
if (War.war.isLoaded()) {
|
if (War.war.isLoaded()) {
|
||||||
// Anyone who died in warzones needs to go back there pronto!
|
// Anyone who died in warzones needs to go back there pronto!
|
||||||
|
@ -11,7 +11,7 @@ import com.tommytony.war.War;
|
|||||||
|
|
||||||
public class WarServerListener implements Listener {
|
public class WarServerListener implements Listener {
|
||||||
|
|
||||||
@EventHandler(event = PluginDisableEvent.class)
|
@EventHandler
|
||||||
public void onPluginDisable(final PluginDisableEvent event) {
|
public void onPluginDisable(final PluginDisableEvent event) {
|
||||||
if (event.getPlugin().getDataFolder().getName().equals("Spout")) {
|
if (event.getPlugin().getDataFolder().getName().equals("Spout")) {
|
||||||
if (War.war.isSpoutServer()) {
|
if (War.war.isSpoutServer()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user