From 7f6c7cd678fd60e7110871b2c28ac7fa99f9b798 Mon Sep 17 00:00:00 2001 From: Calclavia Date: Mon, 23 Dec 2013 10:38:08 +0800 Subject: [PATCH] Fixed different materials merging --- src/resonantinduction/wire/part/PartAdvancedWire.java | 11 +++++++---- src/resonantinduction/wire/part/PartFlatWire.java | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/resonantinduction/wire/part/PartAdvancedWire.java b/src/resonantinduction/wire/part/PartAdvancedWire.java index df157a163..4a0c68acd 100644 --- a/src/resonantinduction/wire/part/PartAdvancedWire.java +++ b/src/resonantinduction/wire/part/PartAdvancedWire.java @@ -23,7 +23,7 @@ import codechicken.lib.data.MCDataOutput; */ public abstract class PartAdvancedWire extends PartConductor { - public static final int DEFAULT_COLOR = 16; + public static final int DEFAULT_COLOR = 15; public int color = DEFAULT_COLOR; public EnumWireMaterial material = EnumWireMaterial.COPPER; @@ -42,17 +42,20 @@ public abstract class PartAdvancedWire extends PartConductor if (this.getMaterial() == wire.getMaterial()) { - System.out.println("COMMON"); if (this.isInsulated() && wire.isInsulated()) { - return this.getColor() == wire.getColor(); + return this.getColor() == wire.getColor() || (this.getColor() == DEFAULT_COLOR || wire.getColor() == DEFAULT_COLOR); } return true; } } + else + { + return CompatibilityModule.isHandler(obj); + } - return CompatibilityModule.isHandler(obj); + return false; } @Override diff --git a/src/resonantinduction/wire/part/PartFlatWire.java b/src/resonantinduction/wire/part/PartFlatWire.java index 62b3da1bf..18306da4f 100644 --- a/src/resonantinduction/wire/part/PartFlatWire.java +++ b/src/resonantinduction/wire/part/PartFlatWire.java @@ -765,7 +765,7 @@ public class PartFlatWire extends PartAdvancedWire implements TFacePart, JNormal public int getThickness() { - return this.isInsulated ? 1 : 0; + return this.isInsulated ? 2 : 1; } @Override