From 428f1a18e7a4048573df8ee22a92ff213e430659 Mon Sep 17 00:00:00 2001 From: Olof Larsson Date: Tue, 2 Jul 2013 10:44:03 +0200 Subject: [PATCH] This is 2.0.2_dev --- plugin.yml | 2 +- .../factions/listeners/FactionsListenerMain.java | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/plugin.yml b/plugin.yml index 3df0dc52..b6730422 100644 --- a/plugin.yml +++ b/plugin.yml @@ -1,6 +1,6 @@ main: com.massivecraft.factions.Factions name: Factions -version: 2.0.1 +version: 2.0.2_dev website: http://massivecraft.com/factions authors: [Cayorion, Brettflan] description: §eFactions allows the players to team up and claim land as their own and start wars with other factions. This way we hope to inspire politics, intrigue, and team spirit. §aCayorion §efrom the minecraft server §aMassiveCraft §eis the lead Factions programmer. Feel free to visit us at §bhttp://massivecraft.com diff --git a/src/com/massivecraft/factions/listeners/FactionsListenerMain.java b/src/com/massivecraft/factions/listeners/FactionsListenerMain.java index 13267573..a1fbd963 100644 --- a/src/com/massivecraft/factions/listeners/FactionsListenerMain.java +++ b/src/com/massivecraft/factions/listeners/FactionsListenerMain.java @@ -240,7 +240,7 @@ public class FactionsListenerMain implements Listener @EventHandler(priority = EventPriority.NORMAL, ignoreCancelled = true) public void canCombatDamageHappen(EntityCombustByEntityEvent event) { - EntityDamageByEntityEvent sub = new EntityDamageByEntityEvent(event.getCombuster(), event.getEntity(), EntityDamageEvent.DamageCause.FIRE, 0); + EntityDamageByEntityEvent sub = new EntityDamageByEntityEvent(event.getCombuster(), event.getEntity(), EntityDamageEvent.DamageCause.FIRE, 0D); if (this.canCombatDamageHappen(sub, false)) return; event.setCancelled(true); } @@ -256,7 +256,7 @@ public class FactionsListenerMain implements Listener // ... scan through affected entities to make sure they're all valid targets. for (LivingEntity affectedEntity : event.getAffectedEntities()) { - EntityDamageByEntityEvent sub = new EntityDamageByEntityEvent(thrower, affectedEntity, EntityDamageEvent.DamageCause.CUSTOM, 0); + EntityDamageByEntityEvent sub = new EntityDamageByEntityEvent(thrower, affectedEntity, EntityDamageEvent.DamageCause.CUSTOM, 0D); if (this.canCombatDamageHappen(sub, true)) continue; // affected entity list doesn't accept modification (iter.remove() is a no-go), but this works @@ -371,7 +371,7 @@ public class FactionsListenerMain implements Listener } // Damage will be dealt. However check if the damage should be reduced. - int damage = event.getDamage(); + double damage = event.getDamage(); if (damage > 0.0 && fdefender.hasFaction() && ownTerritory && uconf.territoryShieldFactor > 0) { int newDamage = (int)Math.ceil(damage * (1D - uconf.territoryShieldFactor));