Fixed packet crash bug
This commit is contained in:
parent
c9831d33db
commit
256c66f7b6
4 changed files with 5 additions and 12 deletions
|
@ -196,7 +196,7 @@ public abstract class PartConductor extends PartAdvanced implements IAdvancedCon
|
||||||
}
|
}
|
||||||
|
|
||||||
this.currentAcceptorConnections = possibleAcceptorConnections;
|
this.currentAcceptorConnections = possibleAcceptorConnections;
|
||||||
this.sendDescUpdate();
|
//this.sendDescUpdate();
|
||||||
}
|
}
|
||||||
|
|
||||||
tile().markRender();
|
tile().markRender();
|
||||||
|
|
|
@ -126,7 +126,7 @@ public class PartFlatWire extends PartWireBase implements TFacePart, JNormalOccl
|
||||||
@Override
|
@Override
|
||||||
public void readDesc(MCDataInput packet)
|
public void readDesc(MCDataInput packet)
|
||||||
{
|
{
|
||||||
// super.readDesc(packet);
|
super.readDesc(packet);
|
||||||
this.side = packet.readByte();
|
this.side = packet.readByte();
|
||||||
this.connMap = packet.readInt();
|
this.connMap = packet.readInt();
|
||||||
}
|
}
|
||||||
|
@ -134,7 +134,7 @@ public class PartFlatWire extends PartWireBase implements TFacePart, JNormalOccl
|
||||||
@Override
|
@Override
|
||||||
public void writeDesc(MCDataOutput packet)
|
public void writeDesc(MCDataOutput packet)
|
||||||
{
|
{
|
||||||
// super.writeDesc(packet);
|
super.writeDesc(packet);
|
||||||
packet.writeByte(this.side);
|
packet.writeByte(this.side);
|
||||||
packet.writeInt(this.connMap);
|
packet.writeInt(this.connMap);
|
||||||
}
|
}
|
||||||
|
@ -142,6 +142,7 @@ public class PartFlatWire extends PartWireBase implements TFacePart, JNormalOccl
|
||||||
@Override
|
@Override
|
||||||
public void read(MCDataInput packet)
|
public void read(MCDataInput packet)
|
||||||
{
|
{
|
||||||
|
super.read(packet);
|
||||||
read(packet, packet.readUByte());
|
read(packet, packet.readUByte());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -581,7 +582,7 @@ public class PartFlatWire extends PartWireBase implements TFacePart, JNormalOccl
|
||||||
|
|
||||||
public boolean useStaticRenderer()
|
public boolean useStaticRenderer()
|
||||||
{
|
{
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -102,9 +102,7 @@ public abstract class PartWireBase extends PartConductor implements IBlockableCo
|
||||||
public void setInsulationColor(int dye)
|
public void setInsulationColor(int dye)
|
||||||
{
|
{
|
||||||
dyeID = dye;
|
dyeID = dye;
|
||||||
|
|
||||||
refresh();
|
refresh();
|
||||||
world().markBlockForUpdate(x(), y(), z());
|
|
||||||
tile().notifyPartChange(this);
|
tile().notifyPartChange(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -113,9 +111,7 @@ public abstract class PartWireBase extends PartConductor implements IBlockableCo
|
||||||
{
|
{
|
||||||
isInsulated = insulated;
|
isInsulated = insulated;
|
||||||
dyeID = DEFAULT_COLOR;
|
dyeID = DEFAULT_COLOR;
|
||||||
|
|
||||||
refresh();
|
refresh();
|
||||||
world().markBlockForUpdate(x(), y(), z());
|
|
||||||
tile().notifyPartChange(this);
|
tile().notifyPartChange(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -123,9 +119,7 @@ public abstract class PartWireBase extends PartConductor implements IBlockableCo
|
||||||
{
|
{
|
||||||
isInsulated = true;
|
isInsulated = true;
|
||||||
dyeID = dyeColour;
|
dyeID = dyeColour;
|
||||||
|
|
||||||
refresh();
|
refresh();
|
||||||
world().markBlockForUpdate(x(), y(), z());
|
|
||||||
tile().notifyPartChange(this);
|
tile().notifyPartChange(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -138,7 +132,6 @@ public abstract class PartWireBase extends PartConductor implements IBlockableCo
|
||||||
{
|
{
|
||||||
dyeID = dye;
|
dyeID = dye;
|
||||||
refresh();
|
refresh();
|
||||||
world().markBlockForUpdate(x(), y(), z());
|
|
||||||
tile().notifyPartChange(this);
|
tile().notifyPartChange(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -58,7 +58,6 @@ public class RenderLainWire
|
||||||
* 2 = side 2 = -Z = NORTH
|
* 2 = side 2 = -Z = NORTH
|
||||||
* 3 = side 5 = +X = EAST
|
* 3 = side 5 = +X = EAST
|
||||||
*/
|
*/
|
||||||
|
|
||||||
private static class WireModelGenerator
|
private static class WireModelGenerator
|
||||||
{
|
{
|
||||||
int side;
|
int side;
|
||||||
|
|
Loading…
Reference in a new issue