Fix 2 cable rendering bugs (#350)

This commit is contained in:
Stone
2024-01-02 10:35:00 -05:00
committed by GitHub
parent 01f56ae633
commit a31de25257
2 changed files with 4 additions and 9 deletions
@@ -331,6 +331,10 @@ class CableBuilder {
TextureAtlasSprite oddChannel = this.smartCableTextures.getOddTextureForChannels((int) (channels / (AEConfig.instance().getNormalChannelCapacity() / 8)));
TextureAtlasSprite evenChannel = this.smartCableTextures.getEvenTextureForChannels((int) (channels / (AEConfig.instance().getNormalChannelCapacity() / 8)));
// Thin part of connector, here to prevent the color of the channels
// from leaking into it
addCoveredCableSizedCube(facing, cubeBuilder);
// For to-machine connections, use a thicker end-cap for the connection
if (connectionType != AECableType.GLASS && !cableBusAdjacent) {
this.addBigCoveredCableSizedCube(facing, cubeBuilder);
@@ -351,7 +355,6 @@ class CableBuilder {
cubeBuilder.setTexture(texture);
}
addCoveredCableSizedCube(facing, cubeBuilder);
// Render the channel indicators brightly lit at night
cubeBuilder.setRenderFullBright(true);
@@ -974,14 +974,6 @@ public class CableBusContainer extends CableBusStorage implements AEMultiTile, I
connectionType = AECableType.min(connectionType, adjacentType);
}
// Check if the adjacent TE is a cable bus or not
if (adjacentTe instanceof IPartHost) {
IPartHost host = (IPartHost) adjacentTe;
if (host.getPart(facing) != null) {
renderState.getCableBusAdjacent().add(facing);
}
}
renderState.getConnectionTypes().put(facing, connectionType);
}