// TODO we're missing the ceramics to hold the power lines
@Override
public void renderTo(Target<?> target) {
VectorXYZ base = getBase().addY(-0.5);
double height = parseHeight(node.getTags(), 14);
Material material = Materials.getSurfaceMaterial(node.getTags().getValue("material"));
if (material == null) {
material = Materials.getSurfaceMaterial(node.getTags().getValue("surface"), Materials.STEEL);
}
// draw base column
target.drawColumn(material, null, base, height, 0.5, 0.25, true, true);
// draw cross "column"
target.drawBox(material, base.add(0, height, 0), config.direction, 0.25, 5, 0.25);
// draw pieces holding the power lines
base = base.add(0, height + 0.25, 0);
target.drawColumn(Materials.CONCRETE, null, base.add(config.direction.rightNormal().mult(2)), 0.5, 0.1, 0.1, true, true);
target.drawColumn(Materials.CONCRETE, null, base.add(config.direction.rightNormal().mult(-2)), 0.5, 0.1, 0.1, true, true);
if (config.cables >= 3) {
target.drawColumn(Materials.CONCRETE, null, base, 0.5, 0.1, 0.1, true, true);
}
if (config.cables >= 5) {
target.drawColumn(Materials.CONCRETE, null, base.add(config.direction.rightNormal().mult(1.5)), -0.5, 0.1, 0.1, true, true);
target.drawColumn(Materials.CONCRETE, null, base.add(config.direction.rightNormal().mult(-1.5)), -0.5, 0.1, 0.1, true, true);
}
}