Implemented facade rendering on the cable bus.
This commit is contained in:
@@ -19,12 +19,14 @@
|
||||
package appeng.client.render.cablebus;
|
||||
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.EnumMap;
|
||||
import java.util.EnumSet;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.util.EnumFacing;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.math.AxisAlignedBB;
|
||||
|
||||
import appeng.api.util.AECableType;
|
||||
import appeng.api.util.AEColor;
|
||||
@@ -63,6 +65,13 @@ public class CableBusRenderState
|
||||
// For each attachment, this contains the distance from the edge until which a cable connection should be drawn
|
||||
private EnumMap<EnumFacing, Integer> attachmentConnections = new EnumMap<>( EnumFacing.class );
|
||||
|
||||
// Contains the facade to use for each side that has a facade attached
|
||||
private EnumMap<EnumFacing, FacadeRenderState> facades = new EnumMap<>( EnumFacing.class );
|
||||
|
||||
// Contains the bounding boxes of all parts on the cable bus to allow facades to cut out holes for the parts. This list is only populated if there are
|
||||
// facades on this cable bus
|
||||
private List<AxisAlignedBB> boundingBoxes = new ArrayList<>();
|
||||
|
||||
public CableCoreType getCoreType()
|
||||
{
|
||||
return coreType;
|
||||
@@ -133,4 +142,14 @@ public class CableBusRenderState
|
||||
return attachmentConnections;
|
||||
}
|
||||
|
||||
public EnumMap<EnumFacing, FacadeRenderState> getFacades()
|
||||
{
|
||||
return facades;
|
||||
}
|
||||
|
||||
public List<AxisAlignedBB> getBoundingBoxes()
|
||||
{
|
||||
return boundingBoxes;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user