private void drawCrossedSquares(
     IBlockAccess blockAccess,
     double x,
     double y,
     double z,
     float size,
     Block block,
     int meta,
     RenderBlocks renderer) {
   Tessellator tessellator = Tessellator.instance;
   IIcon icon = renderer.getBlockIcon(block, blockAccess, (int) x, (int) y, (int) z, meta);
   if (renderer.hasOverrideBlockTexture()) {
     icon = renderer.overrideBlockTexture;
   }
   double minU = (double) icon.getMinU();
   double minV = (double) icon.getMinV();
   double maxU = (double) icon.getMaxU();
   double maxV = (double) icon.getMaxV();
   double scaledSize = 0.45D * (double) size;
   double minX = x + 0.5D - scaledSize;
   double maxX = x + 0.5D + scaledSize;
   double minZ = z + 0.5D - scaledSize;
   double maxZ = z + 0.5D + scaledSize;
   tessellator.addVertexWithUV(minX, y + (double) size, minZ, minU, minV);
   tessellator.addVertexWithUV(minX, y + 0.0D, minZ, minU, maxV);
   tessellator.addVertexWithUV(maxX, y + 0.0D, maxZ, maxU, maxV);
   tessellator.addVertexWithUV(maxX, y + (double) size, maxZ, maxU, minV);
   tessellator.addVertexWithUV(maxX, y + (double) size, maxZ, minU, minV);
   tessellator.addVertexWithUV(maxX, y + 0.0D, maxZ, minU, maxV);
   tessellator.addVertexWithUV(minX, y + 0.0D, minZ, maxU, maxV);
   tessellator.addVertexWithUV(minX, y + (double) size, minZ, maxU, minV);
   tessellator.addVertexWithUV(minX, y + (double) size, maxZ, minU, minV);
   tessellator.addVertexWithUV(minX, y + 0.0D, maxZ, minU, maxV);
   tessellator.addVertexWithUV(maxX, y + 0.0D, minZ, maxU, maxV);
   tessellator.addVertexWithUV(maxX, y + (double) size, minZ, maxU, minV);
   tessellator.addVertexWithUV(maxX, y + (double) size, minZ, minU, minV);
   tessellator.addVertexWithUV(maxX, y + 0.0D, minZ, minU, maxV);
   tessellator.addVertexWithUV(minX, y + 0.0D, maxZ, maxU, maxV);
   tessellator.addVertexWithUV(minX, y + (double) size, maxZ, maxU, minV);
 }
  @Override
  public void renderInventoryBlock(Block block, int metadata, int modelID, RenderBlocks renderer) {
    Tessellator tessellator = Tessellator.instance;
    Icon icon = renderer.getBlockIcon(block);

    float red = 1.0F;
    float green = 1.0F;
    float blue = 1.0F;

    if (renderer.useInventoryTint) {
      int var6 = block.getRenderColor(metadata);

      red = (float) (var6 >> 16 & 255) / 255.0F;
      green = (float) (var6 >> 8 & 255) / 255.0F;
      blue = (float) (var6 & 255) / 255.0F;
    }

    GL11.glRotatef(90.0F, 0.0F, 1.0F, 0.0F);
    GL11.glScalef(1.5F, 1.5F, 1.5F);
    GL11.glTranslatef(-0.5F, -0.4F, -0.5F);
    GL11.glColor4f(red, green, blue, 1.0F);
    GL11.glEnable(GL11.GL_CULL_FACE);

    double minX = 4.0 / 16.0D;
    double minY = 0.0 / 16.0D;
    double minZ = 4.0 / 16.0D;
    double maxX = 12.0 / 16.0D;
    double maxY = 10.0 / 16.0D;
    double maxZ = 12.0 / 16.0D;

    double uvMinU = icon.getInterpolatedU(0.0D);
    double uvMaxU = icon.getInterpolatedU(8.0D);
    double uvMinV = icon.getInterpolatedV(6.0D);
    double uvMaxV = icon.getInterpolatedV(16.0D);

    tessellator.startDrawingQuads();
    {
      tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);

      tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMinU, uvMaxV);

      tessellator.addVertexWithUV(minX, minY, maxZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMaxV);

      tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMinU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMaxU, uvMaxV);

      tessellator.addVertexWithUV(maxX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMinU, uvMaxV);
    }

    uvMinU = icon.getInterpolatedU(8.0D);
    uvMaxU = icon.getInterpolatedU(16.0D);
    uvMinV = icon.getInterpolatedV(8.0D);
    uvMaxV = icon.getInterpolatedV(16.0D);

    {
      tessellator.setColorOpaque_F(0.6F, 0.6F, 0.6F);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(0.6F, 0.6F, 0.6F);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMaxV);
    }

    minY = 2.0D / 16.0D;

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);
    }

    double indent = 3.0D / 16.0D;

    uvMinU = icon.getInterpolatedU(8.0D);
    uvMaxU = icon.getInterpolatedU(16.0D);
    uvMinV = icon.getInterpolatedV(1.0D);
    uvMaxV = icon.getInterpolatedV(8.0D);

    minX = 4.0D / 16.0D;
    maxX = 12.0D / 16.0D;
    minY = 2.0D / 16.0D;
    maxY = 9.0D / 16.0D;
    minZ = 4.0D / 16.0D;
    maxZ = 12.0D / 16.0D;

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX, minY, minZ + indent, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ + indent, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ + indent, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ + indent, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX, minY, minZ + indent, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, minZ + indent, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, minZ + indent, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, minZ + indent, uvMaxU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX, minY, maxZ - indent, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ - indent, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ - indent, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ - indent, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX, minY, maxZ - indent, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, maxZ - indent, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ - indent, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, maxZ - indent, uvMaxU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX + indent, minY, minZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(minX + indent, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX + indent, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX + indent, minY, maxZ, uvMaxU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX + indent, minY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX + indent, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX + indent, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX + indent, minY, minZ, uvMinU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX - indent, minY, maxZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX - indent, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX - indent, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX - indent, minY, minZ, uvMaxU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX - indent, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX - indent, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX - indent, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX - indent, minY, maxZ, uvMinU, uvMaxV);
    }

    uvMinU = icon.getInterpolatedU(0.0D);
    uvMaxU = icon.getInterpolatedU(8.0D);
    uvMinV = icon.getInterpolatedV(1.0D);
    uvMaxV = icon.getInterpolatedV(6.0D);

    minX = 0.25F;
    maxX = 0.75F;
    minY = 10.0F / 16.0F;
    maxY = 15.0F / 16.0F;
    minZ = 0.5F;
    maxZ = 0.5F;

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMaxV);
    }

    tessellator.draw();

    /*tessellator.startDrawingQuads();
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
    tessellator.draw();

    tessellator.startDrawingQuads();
    tessellator.setNormal(0.0F, 1.0F, 0.0F);
    tessellator.draw();

    tessellator.startDrawingQuads();
    tessellator.setNormal(0.0F, 0.0F, -1.0F);
    tessellator.draw();
    tessellator.startDrawingQuads();
    tessellator.setNormal(0.0F, 0.0F, 1.0F);
    tessellator.draw();
    tessellator.startDrawingQuads();
    tessellator.setNormal(-1.0F, 0.0F, 0.0F);
    tessellator.draw();
    tessellator.startDrawingQuads();
    tessellator.setNormal(1.0F, 0.0F, 0.0F);
    tessellator.draw();*/

    GL11.glTranslatef(0.5F, 0.5F, 0.5F);
    GL11.glDisable(GL11.GL_CULL_FACE);
  }
  @Override
  public boolean renderWorldBlock(
      IBlockAccess blockAccess,
      int i,
      int j,
      int k,
      Block bblock,
      int modelId,
      RenderBlocks renderer) {
    BlockLantern block = (BlockLantern) bblock;

    Icon icon =
        renderer.hasOverrideBlockTexture()
            ? renderer.overrideBlockTexture
            : renderer.getBlockIcon(block);
    int brightness = block.getMixedBrightnessForBlock(blockAccess, i, j, k);
    Tessellator tessellator = Tessellator.instance;

    double minX = 4.0 / 16.0D;
    double minY = 0.0 / 16.0D;
    double minZ = 4.0 / 16.0D;
    double maxX = 12.0 / 16.0D;
    double maxY = 10.0 / 16.0D;
    double maxZ = 12.0 / 16.0D;

    double uvMinU = icon.getInterpolatedU(0.0D);
    double uvMaxU = icon.getInterpolatedU(8.0D);
    double uvMinV = icon.getInterpolatedV(6.0D);
    double uvMaxV = icon.getInterpolatedV(16.0D);

    tessellator.setBrightness(brightness);

    tessellator.addTranslation((float) i, (float) j, (float) k);

    {
      tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);

      tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMinU, uvMaxV);

      tessellator.addVertexWithUV(minX, minY, maxZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMaxV);

      tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMinU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMaxU, uvMaxV);

      tessellator.addVertexWithUV(maxX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMinU, uvMaxV);
    }

    uvMinU = icon.getInterpolatedU(8.0D);
    uvMaxU = icon.getInterpolatedU(16.0D);
    uvMinV = icon.getInterpolatedV(8.0D);
    uvMaxV = icon.getInterpolatedV(16.0D);

    {
      tessellator.setColorOpaque_F(0.6F, 0.6F, 0.6F);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(0.6F, 0.6F, 0.6F);
      tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMaxV);
    }

    minY = 2.0D / 16.0D;

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);
    }

    double indent = 3.0D / 16.0D;

    uvMinU = icon.getInterpolatedU(8.0D);
    uvMaxU = icon.getInterpolatedU(16.0D);
    uvMinV = icon.getInterpolatedV(1.0D);
    uvMaxV = icon.getInterpolatedV(8.0D);

    minX = 4.0D / 16.0D;
    maxX = 12.0D / 16.0D;
    minY = 2.0D / 16.0D;
    maxY = 9.0D / 16.0D;
    minZ = 4.0D / 16.0D;
    maxZ = 12.0D / 16.0D;

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX, minY, minZ + indent, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, minZ + indent, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, minZ + indent, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, minZ + indent, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX, minY, minZ + indent, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, minZ + indent, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, minZ + indent, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, minZ + indent, uvMaxU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX, minY, maxZ - indent, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ - indent, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX, maxY, maxZ - indent, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX, minY, maxZ - indent, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX, minY, maxZ - indent, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(minX, maxY, maxZ - indent, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX, maxY, maxZ - indent, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX, minY, maxZ - indent, uvMaxU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX + indent, minY, minZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(minX + indent, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX + indent, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX + indent, minY, maxZ, uvMaxU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(minX + indent, minY, maxZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(minX + indent, maxY, maxZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(minX + indent, maxY, minZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(minX + indent, minY, minZ, uvMinU, uvMaxV);
    }

    {
      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX - indent, minY, maxZ, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(maxX - indent, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX - indent, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX - indent, minY, minZ, uvMaxU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(maxX - indent, minY, minZ, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(maxX - indent, maxY, minZ, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(maxX - indent, maxY, maxZ, uvMinU, uvMinV);
      tessellator.addVertexWithUV(maxX - indent, minY, maxZ, uvMinU, uvMaxV);
    }

    uvMinU = icon.getInterpolatedU(0.0D);
    uvMaxU = icon.getInterpolatedU(8.0D);
    uvMinV = icon.getInterpolatedV(1.0D);
    uvMaxV = icon.getInterpolatedV(6.0D);

    float handleRot = 0.0F;
    boolean renderDoubleHandle = false;

    boolean s1 = false;
    boolean s2 = false;
    boolean s3 = false;
    boolean s4 = false;

    if (blockAccess.isBlockOpaqueCube(i, j + 1, k)) {
      renderDoubleHandle = true;
      handleRot = 45.0F;
    } else if (!blockAccess.isBlockOpaqueCube(i, j - 1, k)) {
      s1 = blockAccess.isBlockOpaqueCube(i - 1, j, k);
      s2 = blockAccess.isBlockOpaqueCube(i, j, k - 1);
      s3 = blockAccess.isBlockOpaqueCube(i + 1, j, k);
      s4 = blockAccess.isBlockOpaqueCube(i, j, k + 1);

      if (s1 & s2 & s3 & s4) {
        handleRot = 45.0F;
      } else if ((s1 & s2) | (s3 & s4)) {
        handleRot = 45.0F;
      } else if ((s2 & s3) | (s4 & s1)) {
        handleRot = -45.0F;
      } else if (!s2 & !s4) {
        handleRot = 0.0F;
      } else if (!s1 & !s3) {
        handleRot = 90.0F;
      }
    }

    {
      double x1 = 0.5D - Math.sin(handleRot * Math.PI / 180.0D) * 0.25D;
      double x2 = 1.0D - x1;
      double z1 = 0.5D - Math.cos(handleRot * Math.PI / 180.0D) * 0.25D;
      double z2 = 1.0D - z1;
      double y1 = 10.0D / 16.0D;
      double y2 = 15.0D / 16.0D;

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(x1, y1, z1, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(x1, y2, z1, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(x2, y2, z2, uvMinU, uvMinV);
      tessellator.addVertexWithUV(x2, y1, z2, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(x2, y1, z2, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(x2, y2, z2, uvMinU, uvMinV);
      tessellator.addVertexWithUV(x1, y2, z1, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(x1, y1, z1, uvMaxU, uvMaxV);
    }

    if (renderDoubleHandle) {
      double x1 = 0.5D - Math.sin((handleRot + 90) * Math.PI / 180.0D) * 0.25D;
      double x2 = 1.0D - x1;
      double z1 = 0.5D - Math.cos((handleRot + 90) * Math.PI / 180.0D) * 0.25D;
      double z2 = 1.0D - z1;
      double y1 = 18.0D / 16.0D;
      double y2 = 13.0D / 16.0D;

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(x1, y1, z1, uvMaxU, uvMaxV);
      tessellator.addVertexWithUV(x1, y2, z1, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(x2, y2, z2, uvMinU, uvMinV);
      tessellator.addVertexWithUV(x2, y1, z2, uvMinU, uvMaxV);

      tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
      tessellator.addVertexWithUV(x2, y1, z2, uvMinU, uvMaxV);
      tessellator.addVertexWithUV(x2, y2, z2, uvMinU, uvMinV);
      tessellator.addVertexWithUV(x1, y2, z1, uvMaxU, uvMinV);
      tessellator.addVertexWithUV(x1, y1, z1, uvMaxU, uvMaxV);
    } else {
      uvMinV = icon.getInterpolatedV(0.0D);
      uvMaxV = icon.getInterpolatedV(1.0D);
      minY = 13.0D / 16.0D;
      maxY = 14.0D / 16.0D;

      if (s1 | s3) {
        uvMinU = icon.getInterpolatedU(0.0D);
        uvMaxU = icon.getInterpolatedU(16.0D);

        minZ = 7.5D / 16.0D;
        maxZ = 1.0D - minZ;

        if (s1) {
          uvMinU = icon.getInterpolatedU(0.0D);
          minX = 0.0D;
        } else {
          uvMinU = icon.getInterpolatedU(7.0D);
          minX = 6.0D / 16.0D;

          double uv2MinU = icon.getInterpolatedU(0.0D);
          double uv2MaxU = icon.getInterpolatedU(1.0D);
          double uv2MinV = icon.getInterpolatedV(0.0D);
          double uv2MaxV = icon.getInterpolatedV(1.0D);

          tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
          tessellator.addVertexWithUV(minX, minY, maxZ, uv2MinU, uv2MaxV);
          tessellator.addVertexWithUV(minX, maxY, maxZ, uv2MinU, uv2MinV);
          tessellator.addVertexWithUV(minX, maxY, minZ, uv2MaxU, uv2MinV);
          tessellator.addVertexWithUV(minX, minY, minZ, uv2MaxU, uv2MaxV);
        }

        if (s3) {
          uvMaxU = icon.getInterpolatedU(16.0D);
          maxX = 1.0D;
        } else {
          uvMaxU = icon.getInterpolatedU(9.0D);
          maxX = 10.0D / 16.0D;

          double uv2MinU = icon.getInterpolatedU(0.0D);
          double uv2MaxU = icon.getInterpolatedU(1.0D);
          double uv2MinV = icon.getInterpolatedV(0.0D);
          double uv2MaxV = icon.getInterpolatedV(1.0D);

          tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
          tessellator.addVertexWithUV(maxX, minY, minZ, uv2MinU, uv2MaxV);
          tessellator.addVertexWithUV(maxX, maxY, minZ, uv2MinU, uv2MinV);
          tessellator.addVertexWithUV(maxX, maxY, maxZ, uv2MaxU, uv2MinV);
          tessellator.addVertexWithUV(maxX, minY, maxZ, uv2MaxU, uv2MaxV);
        }

        tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
        tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMaxV);
        tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
        tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
        tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMaxV);

        tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
        tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);
        tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
        tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
        tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);

        tessellator.setColorOpaque_F(0.6F, 0.6F, 0.6F);
        tessellator.addVertexWithUV(maxX, minY, minZ, uvMaxU, uvMaxV);
        tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMinV);
        tessellator.addVertexWithUV(minX, minY, maxZ, uvMinU, uvMinV);
        tessellator.addVertexWithUV(minX, minY, minZ, uvMinU, uvMaxV);

        tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
        tessellator.addVertexWithUV(maxX, minY, maxZ, uvMinU, uvMaxV);
        tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMinV);
        tessellator.addVertexWithUV(minX, maxY, maxZ, uvMaxU, uvMinV);
        tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMaxV);
      }

      if (s2 | s4) {
        uvMinU = icon.getInterpolatedU(0.0D);
        uvMaxU = icon.getInterpolatedU(16.0D);

        minX = 7.5D / 16.0D;
        maxX = 1.0D - minX;

        if (s2) {
          uvMinU = icon.getInterpolatedU(0.0D);
          minZ = 0.0D;
        } else {
          uvMinU = icon.getInterpolatedU(7.0D);
          minZ = 6.0D / 16.0D;

          double uv2MinU = icon.getInterpolatedU(0.0D);
          double uv2MaxU = icon.getInterpolatedU(1.0D);
          double uv2MinV = icon.getInterpolatedV(0.0D);
          double uv2MaxV = icon.getInterpolatedV(1.0D);

          tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
          tessellator.addVertexWithUV(minX, minY, minZ, uv2MaxU, uv2MaxV);
          tessellator.addVertexWithUV(minX, maxY, minZ, uv2MaxU, uv2MinV);
          tessellator.addVertexWithUV(maxX, maxY, minZ, uv2MinU, uv2MinV);
          tessellator.addVertexWithUV(maxX, minY, minZ, uv2MinU, uv2MaxV);
        }

        if (s4) {
          uvMaxU = icon.getInterpolatedU(16.0D);
          maxZ = 1.0D;
        } else {
          uvMaxU = icon.getInterpolatedU(9.0D);
          maxZ = 10.0D / 16.0D;

          double uv2MinU = icon.getInterpolatedU(0.0D);
          double uv2MaxU = icon.getInterpolatedU(1.0D);
          double uv2MinV = icon.getInterpolatedV(0.0D);
          double uv2MaxV = icon.getInterpolatedV(1.0D);

          tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
          tessellator.addVertexWithUV(maxX, minY, maxZ, uv2MaxU, uv2MaxV);
          tessellator.addVertexWithUV(maxX, maxY, maxZ, uv2MaxU, uv2MinV);
          tessellator.addVertexWithUV(minX, maxY, maxZ, uv2MinU, uv2MinV);
          tessellator.addVertexWithUV(minX, minY, maxZ, uv2MinU, uv2MaxV);
        }

        tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);
        tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMinU, uvMaxV);
        tessellator.addVertexWithUV(maxX, maxY, minZ, uvMaxU, uvMaxV);
        tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
        tessellator.addVertexWithUV(minX, maxY, maxZ, uvMinU, uvMinV);

        tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
        tessellator.addVertexWithUV(minX, minY, maxZ, uvMinU, uvMaxV);
        tessellator.addVertexWithUV(minX, maxY, maxZ, uvMinU, uvMinV);
        tessellator.addVertexWithUV(minX, maxY, minZ, uvMaxU, uvMinV);
        tessellator.addVertexWithUV(minX, minY, minZ, uvMaxU, uvMaxV);

        tessellator.setColorOpaque_F(0.6F, 0.6F, 0.6F);
        tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);
        tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMaxV);
        tessellator.addVertexWithUV(minX, minY, maxZ, uvMaxU, uvMinV);
        tessellator.addVertexWithUV(minX, minY, minZ, uvMinU, uvMinV);

        tessellator.setColorOpaque_F(0.8F, 0.8F, 0.8F);
        tessellator.addVertexWithUV(maxX, minY, minZ, uvMinU, uvMaxV);
        tessellator.addVertexWithUV(maxX, maxY, minZ, uvMinU, uvMinV);
        tessellator.addVertexWithUV(maxX, maxY, maxZ, uvMaxU, uvMinV);
        tessellator.addVertexWithUV(maxX, minY, maxZ, uvMaxU, uvMaxV);
      }
    }

    tessellator.addTranslation((float) -i, (float) -j, (float) -k);

    return true;
  }
Exemplo n.º 4
0
  @Override
  public boolean renderWorldBlock(
      IBlockAccess world,
      int par2,
      int par3,
      int par4,
      Block par1Block,
      int modelId,
      RenderBlocks renderer) {
    if (modelId == model) {
      int l = renderer.blockAccess.getBlockMetadata(par2, par3, par4);
      int i1 = l & 7;
      boolean flag = (l & 8) > 0;
      Tessellator tessellator = Tessellator.instance;
      boolean flag1 = renderer.hasOverrideBlockTexture();

      if (!flag1) {
        renderer.setOverrideBlockTexture(renderer.getBlockIcon(Block.netherrack));
      }

      float f = 0.25F;
      float f1 = 0.1875F;
      float f2 = 0.1875F;

      if (i1 == 5) {
        renderer.setRenderBounds(
            (double) (0.5F - f1),
            0.0D,
            (double) (0.5F - f),
            (double) (0.5F + f1),
            (double) f2,
            (double) (0.5F + f));
      } else if (i1 == 6) {
        renderer.setRenderBounds(
            (double) (0.5F - f),
            0.0D,
            (double) (0.5F - f1),
            (double) (0.5F + f),
            (double) f2,
            (double) (0.5F + f1));
      } else if (i1 == 4) {
        renderer.setRenderBounds(
            (double) (0.5F - f1),
            (double) (0.5F - f),
            (double) (1.0F - f2),
            (double) (0.5F + f1),
            (double) (0.5F + f),
            1.0D);
      } else if (i1 == 3) {
        renderer.setRenderBounds(
            (double) (0.5F - f1),
            (double) (0.5F - f),
            0.0D,
            (double) (0.5F + f1),
            (double) (0.5F + f),
            (double) f2);
      } else if (i1 == 2) {
        renderer.setRenderBounds(
            (double) (1.0F - f2),
            (double) (0.5F - f),
            (double) (0.5F - f1),
            1.0D,
            (double) (0.5F + f),
            (double) (0.5F + f1));
      } else if (i1 == 1) {
        renderer.setRenderBounds(
            0.0D,
            (double) (0.5F - f),
            (double) (0.5F - f1),
            (double) f2,
            (double) (0.5F + f),
            (double) (0.5F + f1));
      } else if (i1 == 0) {
        renderer.setRenderBounds(
            (double) (0.5F - f),
            (double) (1.0F - f2),
            (double) (0.5F - f1),
            (double) (0.5F + f),
            1.0D,
            (double) (0.5F + f1));
      } else if (i1 == 7) {
        renderer.setRenderBounds(
            (double) (0.5F - f1),
            (double) (1.0F - f2),
            (double) (0.5F - f),
            (double) (0.5F + f1),
            1.0D,
            (double) (0.5F + f));
      }

      renderer.renderStandardBlock(par1Block, par2, par3, par4);

      if (!flag1) {
        renderer.clearOverrideBlockTexture();
      }

      tessellator.setBrightness(
          par1Block.getMixedBrightnessForBlock(renderer.blockAccess, par2, par3, par4));
      float f3 = 1.0F;

      if (Block.lightValue[par1Block.blockID] > 0) {
        f3 = 1.0F;
      }

      tessellator.setColorOpaque_F(f3, f3, f3);
      Icon icon = renderer.getBlockIconFromSide(par1Block, 0);

      if (renderer.hasOverrideBlockTexture()) {
        icon = renderer.overrideBlockTexture;
      }

      double d0 = (double) icon.getMinU();
      double d1 = (double) icon.getMinV();
      double d2 = (double) icon.getMaxU();
      double d3 = (double) icon.getMaxV();
      Vec3[] avec3 = new Vec3[8];
      float f4 = 0.0625F;
      float f5 = 0.0625F;
      float f6 = 0.625F;
      avec3[0] =
          renderer
              .blockAccess
              .getWorldVec3Pool()
              .getVecFromPool((double) (-f4), 0.0D, (double) (-f5));
      avec3[1] =
          renderer.blockAccess.getWorldVec3Pool().getVecFromPool((double) f4, 0.0D, (double) (-f5));
      avec3[2] =
          renderer.blockAccess.getWorldVec3Pool().getVecFromPool((double) f4, 0.0D, (double) f5);
      avec3[3] =
          renderer.blockAccess.getWorldVec3Pool().getVecFromPool((double) (-f4), 0.0D, (double) f5);
      avec3[4] =
          renderer
              .blockAccess
              .getWorldVec3Pool()
              .getVecFromPool((double) (-f4), (double) f6, (double) (-f5));
      avec3[5] =
          renderer
              .blockAccess
              .getWorldVec3Pool()
              .getVecFromPool((double) f4, (double) f6, (double) (-f5));
      avec3[6] =
          renderer
              .blockAccess
              .getWorldVec3Pool()
              .getVecFromPool((double) f4, (double) f6, (double) f5);
      avec3[7] =
          renderer
              .blockAccess
              .getWorldVec3Pool()
              .getVecFromPool((double) (-f4), (double) f6, (double) f5);

      for (int j1 = 0; j1 < 8; ++j1) {
        if (flag) {
          avec3[j1].zCoord -= 0.0625D;
          avec3[j1].rotateAroundX(((float) Math.PI * 2F / 9F));
        } else {
          avec3[j1].zCoord += 0.0625D;
          avec3[j1].rotateAroundX(-((float) Math.PI * 2F / 9F));
        }

        if (i1 == 0 || i1 == 7) {
          avec3[j1].rotateAroundZ((float) Math.PI);
        }

        if (i1 == 6 || i1 == 0) {
          avec3[j1].rotateAroundY(((float) Math.PI / 2F));
        }

        if (i1 > 0 && i1 < 5) {
          avec3[j1].yCoord -= 0.375D;
          avec3[j1].rotateAroundX(((float) Math.PI / 2F));

          if (i1 == 4) {
            avec3[j1].rotateAroundY(0.0F);
          }

          if (i1 == 3) {
            avec3[j1].rotateAroundY((float) Math.PI);
          }

          if (i1 == 2) {
            avec3[j1].rotateAroundY(((float) Math.PI / 2F));
          }

          if (i1 == 1) {
            avec3[j1].rotateAroundY(-((float) Math.PI / 2F));
          }

          avec3[j1].xCoord += (double) par2 + 0.5D;
          avec3[j1].yCoord += (double) ((float) par3 + 0.5F);
          avec3[j1].zCoord += (double) par4 + 0.5D;
        } else if (i1 != 0 && i1 != 7) {
          avec3[j1].xCoord += (double) par2 + 0.5D;
          avec3[j1].yCoord += (double) ((float) par3 + 0.125F);
          avec3[j1].zCoord += (double) par4 + 0.5D;
        } else {
          avec3[j1].xCoord += (double) par2 + 0.5D;
          avec3[j1].yCoord += (double) ((float) par3 + 0.875F);
          avec3[j1].zCoord += (double) par4 + 0.5D;
        }
      }

      Vec3 vec3 = null;
      Vec3 vec31 = null;
      Vec3 vec32 = null;
      Vec3 vec33 = null;

      for (int k1 = 0; k1 < 6; ++k1) {
        if (k1 == 0) {
          d0 = (double) icon.getInterpolatedU(7.0D);
          d1 = (double) icon.getInterpolatedV(6.0D);
          d2 = (double) icon.getInterpolatedU(9.0D);
          d3 = (double) icon.getInterpolatedV(8.0D);
        } else if (k1 == 2) {
          d0 = (double) icon.getInterpolatedU(7.0D);
          d1 = (double) icon.getInterpolatedV(6.0D);
          d2 = (double) icon.getInterpolatedU(9.0D);
          d3 = (double) icon.getMaxV();
        }

        if (k1 == 0) {
          vec3 = avec3[0];
          vec31 = avec3[1];
          vec32 = avec3[2];
          vec33 = avec3[3];
        } else if (k1 == 1) {
          vec3 = avec3[7];
          vec31 = avec3[6];
          vec32 = avec3[5];
          vec33 = avec3[4];
        } else if (k1 == 2) {
          vec3 = avec3[1];
          vec31 = avec3[0];
          vec32 = avec3[4];
          vec33 = avec3[5];
        } else if (k1 == 3) {
          vec3 = avec3[2];
          vec31 = avec3[1];
          vec32 = avec3[5];
          vec33 = avec3[6];
        } else if (k1 == 4) {
          vec3 = avec3[3];
          vec31 = avec3[2];
          vec32 = avec3[6];
          vec33 = avec3[7];
        } else if (k1 == 5) {
          vec3 = avec3[0];
          vec31 = avec3[3];
          vec32 = avec3[7];
          vec33 = avec3[4];
        }

        tessellator.addVertexWithUV(vec3.xCoord, vec3.yCoord, vec3.zCoord, d0, d3);
        tessellator.addVertexWithUV(vec31.xCoord, vec31.yCoord, vec31.zCoord, d2, d3);
        tessellator.addVertexWithUV(vec32.xCoord, vec32.yCoord, vec32.zCoord, d2, d1);
        tessellator.addVertexWithUV(vec33.xCoord, vec33.yCoord, vec33.zCoord, d0, d1);
      }
    }
    return true;
  }