From 16de6af58f1281a3ac79789df148ecd092b55a6a Mon Sep 17 00:00:00 2001 From: astoria Date: Mon, 3 Apr 2023 11:54:24 -0500 Subject: [PATCH] Update on connection made --- .../java/net/brokenmoon/afloydwiremod/gui/GuiWiring.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/net/brokenmoon/afloydwiremod/gui/GuiWiring.java b/src/main/java/net/brokenmoon/afloydwiremod/gui/GuiWiring.java index 4d1d112..519bde6 100644 --- a/src/main/java/net/brokenmoon/afloydwiremod/gui/GuiWiring.java +++ b/src/main/java/net/brokenmoon/afloydwiremod/gui/GuiWiring.java @@ -73,6 +73,7 @@ public class GuiWiring extends GuiScrollable { } else if(!this.tool.type.equals("unpaired")) { if(this.tool.type.equals("input")) { wireEntity.outputs[guibutton.slot].wire = new WireConnection(this.tool.x, this.tool.y, this.tool.z, guibutton.slot, tool.slot, tool.xadd, tool.yadd, tool.zadd, tool.sideadd, false, tool.red, tool.green, tool.blue, tool.alpha, tool.width); + wireEntity.updateIO(); tool.xadd = new ArrayList(); tool.yadd = new ArrayList(); tool.zadd = new ArrayList(); @@ -80,8 +81,10 @@ public class GuiWiring extends GuiScrollable { tool.type = "unpaired"; } else if(this.tool.type.equals("output")) { AbstractWireTileEntity otherEntity = (AbstractWireTileEntity)Minecraft.getMinecraft().theWorld.getBlockTileEntity(tool.x, tool.y, tool.z); - if(otherEntity != null) + if(otherEntity != null) { otherEntity.outputs[tool.slot].wire = new WireConnection(this.wireEntity.xCoord, this.wireEntity.yCoord, this.wireEntity.zCoord, tool.slot, guibutton.slot, tool.xadd, tool.yadd, tool.zadd, tool.sideadd, true, tool.red, tool.green, tool.blue, tool.alpha, tool.width); + otherEntity.updateIO(); + } tool.xadd = new ArrayList(); tool.yadd = new ArrayList(); tool.zadd = new ArrayList();