From bb33f0b7d20608d3b69da6263a1a5b2b6a3d8f43 Mon Sep 17 00:00:00 2001 From: fewizz Date: Mon, 28 Dec 2015 18:31:36 +0300 Subject: [PATCH] 1.2.5 --- build.properties | 2 +- .../java/tombenpotter/emt/ModInformation.java | 2 +- .../emt/common/entity/EntityShield.java | 20 ++----------------- 3 files changed, 4 insertions(+), 20 deletions(-) diff --git a/build.properties b/build.properties index 7761dc5..21b740d 100644 --- a/build.properties +++ b/build.properties @@ -3,5 +3,5 @@ package_group=com.tombenpotter.emt mc_version=1.7.10 forge_version=10.13.4.1566 -mod_version=1.2.4 +mod_version=1.2.5 mod_name=ElectroMagicTools diff --git a/src/main/java/tombenpotter/emt/ModInformation.java b/src/main/java/tombenpotter/emt/ModInformation.java index 66cdbfb..b915de6 100644 --- a/src/main/java/tombenpotter/emt/ModInformation.java +++ b/src/main/java/tombenpotter/emt/ModInformation.java @@ -4,7 +4,7 @@ public class ModInformation { public static final String name = "Electro-Magic Tools"; public static final String modid = "EMT"; - public static final String version = "1.2.4"; + public static final String version = "1.2.5"; public static final String texturePath = "electromagictools"; public static final String guiFactory = "tombenpotter.emt.client.gui.config.EMTGuiFactory"; public static final String clientProxy = "tombenpotter.emt.proxy.ClientProxy"; diff --git a/src/main/java/tombenpotter/emt/common/entity/EntityShield.java b/src/main/java/tombenpotter/emt/common/entity/EntityShield.java index b3421f9..55d1527 100644 --- a/src/main/java/tombenpotter/emt/common/entity/EntityShield.java +++ b/src/main/java/tombenpotter/emt/common/entity/EntityShield.java @@ -72,7 +72,7 @@ public class EntityShield extends Entity { owner = this.worldObj.getPlayerEntityByName(dataWatcher.getWatchableObjectString(11)); needCheck = false; } - else if(!needCheck && owner == null){ + if(!needCheck && owner == null){ this.setDead(); return; } @@ -94,23 +94,7 @@ public class EntityShield extends Entity { if (entity.riddenByEntity != this && entity.ridingEntity != this) { double ePosX = entity.posX - this.posX; double ePosZ = entity.posZ - this.posZ; - double d2 = MathHelper.abs_max(ePosX, ePosZ); - d2 = (double) MathHelper.sqrt_double(d2); - ePosX /= d2; - ePosZ /= d2; - double d3 = 1.0D / d2; - - if (d3 > 1.0D) { - d3 = 1.0D; - } - - ePosX *= d3; - ePosZ *= d3; - ePosX *= 0.05000000074505806D; - ePosZ *= 0.05000000074505806D; - ePosX *= (double) (1.0F - this.entityCollisionReduction); - ePosZ *= (double) (1.0F - this.entityCollisionReduction); - entity.addVelocity(ePosX * 10, 0.0D, ePosZ * 10); + entity.addVelocity(ePosX / 5D, 0.0D, ePosZ / 5D); } }