From b5f6450d0a269a91606f4beefd53c14ee48223ba Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Wed, 16 Dec 2015 21:10:28 +0100 Subject: [PATCH] Some more particle tweaks --- .../actuallyadditions/misc/EntityColoredParticleFX.java | 4 ++-- .../ellpeck/actuallyadditions/network/PacketParticle.java | 2 +- .../ellpeck/actuallyadditions/tile/TileEntityLaserRelay.java | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/ellpeck/actuallyadditions/misc/EntityColoredParticleFX.java b/src/main/java/ellpeck/actuallyadditions/misc/EntityColoredParticleFX.java index 2617aa545..98943dca0 100644 --- a/src/main/java/ellpeck/actuallyadditions/misc/EntityColoredParticleFX.java +++ b/src/main/java/ellpeck/actuallyadditions/misc/EntityColoredParticleFX.java @@ -18,10 +18,10 @@ import net.minecraft.world.World; @SideOnly(Side.CLIENT) public class EntityColoredParticleFX extends EntityReddustFX{ - public EntityColoredParticleFX(World world, double x, double y, double z, float size, float r, float g, float b, int ageMulti){ + public EntityColoredParticleFX(World world, double x, double y, double z, float size, float r, float g, float b, float ageMulti){ super(world, x, y, z, size, r, g, b); //To work around Reddust particles resetting the color to red if it's 0 (which is really stupid to be honest) this.particleRed = ((float)(Math.random()*0.20000000298023224D)+0.8F)*r*((float)Math.random()*0.4F+0.6F); - this.particleMaxAge = (int)(8.0D/(Math.random()*0.8D+0.2D))*ageMulti; + this.particleMaxAge = (int)((8.0D/(Math.random()*0.8D+0.2D))*ageMulti); } } diff --git a/src/main/java/ellpeck/actuallyadditions/network/PacketParticle.java b/src/main/java/ellpeck/actuallyadditions/network/PacketParticle.java index 165d0440a..6b45821a8 100644 --- a/src/main/java/ellpeck/actuallyadditions/network/PacketParticle.java +++ b/src/main/java/ellpeck/actuallyadditions/network/PacketParticle.java @@ -93,7 +93,7 @@ public class PacketParticle implements IMessage{ } } - public static void renderParticlesFromAToB(int startX, int startY, int startZ, int endX, int endY, int endZ, int particleAmount, float particleSize, float[] color, int ageMultiplier){ + public static void renderParticlesFromAToB(int startX, int startY, int startZ, int endX, int endY, int endZ, int particleAmount, float particleSize, float[] color, float ageMultiplier){ World world = Minecraft.getMinecraft().theWorld; if(Minecraft.getMinecraft().thePlayer.getDistance(startX, startY, startZ) <= 64 || Minecraft.getMinecraft().thePlayer.getDistance(endX, endY, endZ) <= 64){ diff --git a/src/main/java/ellpeck/actuallyadditions/tile/TileEntityLaserRelay.java b/src/main/java/ellpeck/actuallyadditions/tile/TileEntityLaserRelay.java index 745d1336a..1559bde67 100644 --- a/src/main/java/ellpeck/actuallyadditions/tile/TileEntityLaserRelay.java +++ b/src/main/java/ellpeck/actuallyadditions/tile/TileEntityLaserRelay.java @@ -49,7 +49,7 @@ public class TileEntityLaserRelay extends TileEntityBase implements IEnergyRecei if(network != null){ for(LaserRelayConnectionHandler.ConnectionPair aPair : network.connections){ if(aPair.contains(thisPos) && thisPos.isEqual(aPair.firstRelay)){ - PacketParticle.renderParticlesFromAToB(aPair.firstRelay.getX(), aPair.firstRelay.getY(), aPair.firstRelay.getZ(), aPair.secondRelay.getX(), aPair.secondRelay.getY(), aPair.secondRelay.getZ(), ConfigBoolValues.LESS_LASER_RELAY_PARTICLES.isEnabled() ? 1 : 6, 0.6F, COLOR, 1); + PacketParticle.renderParticlesFromAToB(aPair.firstRelay.getX(), aPair.firstRelay.getY(), aPair.firstRelay.getZ(), aPair.secondRelay.getX(), aPair.secondRelay.getY(), aPair.secondRelay.getZ(), ConfigBoolValues.LESS_LASER_RELAY_PARTICLES.isEnabled() ? 1 : 6, 0.6F, COLOR, 0.6F); } } }