From 50d62a1298f05d6d440a5bc261a0fdf9ffece893 Mon Sep 17 00:00:00 2001 From: Foghrye4 Date: Wed, 31 May 2017 21:23:10 +0300 Subject: energy net fix attempt --- ihl/flexible_cable/SubAnchorEnergyNetNode.java | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'ihl/flexible_cable/SubAnchorEnergyNetNode.java') diff --git a/ihl/flexible_cable/SubAnchorEnergyNetNode.java b/ihl/flexible_cable/SubAnchorEnergyNetNode.java index 3fb9f76..5fd4d91 100644 --- a/ihl/flexible_cable/SubAnchorEnergyNetNode.java +++ b/ihl/flexible_cable/SubAnchorEnergyNetNode.java @@ -23,7 +23,7 @@ public class SubAnchorEnergyNetNode implements IEnergyNetNode{ private AnchorTileEntity base; private short facing; private int gridID=-1; - private Set cableList = new HashSet(); + private Set cableList = new HashSet(); public SubAnchorEnergyNetNode(AnchorTileEntity base1, short facing1) { @@ -129,11 +129,11 @@ public class SubAnchorEnergyNetNode implements IEnergyNetNode{ public boolean addCable(NBTTagCompound cable) { base.hasCableOnSide[this.facing]=true; - return this.cableList.add(cable); + return this.cableList.add(IHLCable.fromNBT(cable)); } @Override - public Set getCableList() { + public Set getCableList() { return cableList; } @@ -156,9 +156,9 @@ public class SubAnchorEnergyNetNode implements IEnergyNetNode{ { NBTTagCompound nbt = new NBTTagCompound(); NBTTagList cableNBTList = new NBTTagList(); - for(NBTTagCompound cable:this.cableList) + for(IHLCable cable:this.cableList) { - cableNBTList.appendTag(cable); + cableNBTList.appendTag(cable.toNBT()); } nbt.setTag("cableList", cableNBTList); nbt.setInteger("gridID", this.gridID); @@ -169,7 +169,7 @@ public class SubAnchorEnergyNetNode implements IEnergyNetNode{ NBTTagList cableNBTList=nbt.getTagList("cableList", 10); for(int i=0;i