Esempio n. 1
0
 @Override
 public void renderInvBlock(RenderBlocks renderblocks, int md) {
   super.block.setBlockBoundsForItemRender();
   this.context.setDefaults();
   this.context.setPos(-0.5D, -0.5D, -0.5D);
   this.context.useNormal = true;
   // RenderLib.bindTexture("/eloraam/machine/machine1.png");
   Tessellator tessellator = Tessellator.instance;
   tessellator.startDrawingQuads();
   this.context.setIcon(
       super.block.getIcon(58, md),
       super.block.getIcon(49, md),
       super.block.getIcon(51, md),
       super.block.getIcon(51, md),
       super.block.getIcon(51, md),
       super.block.getIcon(51, md));
   this.context.renderBox(63, 0.0D, 0.0D, 0.0D, 1.0D, 1.0D, 1.0D);
   tessellator.draw();
   // RenderLib.unbindTexture();
   this.context.useNormal = false;
 }
Esempio n. 2
0
  @Override
  public void renderInvBlock(RenderBlocks renderblocks, int md) {
    super.block.setBlockBoundsForItemRender();
    this.context.setDefaults();
    this.context.setPos(-0.5D, -0.5D, -0.5D);
    this.context.useNormal = true;
    // RenderLib.bindTexture("/eloraam/machine/machine1.png");
    Tessellator tessellator = Tessellator.instance;
    tessellator.startDrawingQuads();
    if (md == 0) {
      this.context.setIcon(
          getIcon(48, md),
          getIcon(53, md),
          getIcon(56, md),
          getIcon(56, md),
          getIcon(55, md),
          getIcon(55, md));
    } else if (md == 2) {
      this.context.setIcon(
          getIcon(58, md),
          getIcon(57, md),
          getIcon(59, md),
          getIcon(59, md),
          getIcon(59, md),
          getIcon(59, md));
    } else if (md == 4) {
      this.context.setIcon(
          getIcon(102, md),
          getIcon(103, md),
          getIcon(98, md),
          getIcon(98, md),
          getIcon(96, md),
          getIcon(96, md));
    } else if (md == 5) {
      this.context.setIcon(
          getIcon(113, md),
          getIcon(112, md),
          getIcon(117, md),
          getIcon(117, md),
          getIcon(117, md),
          getIcon(117, md));
    } else if (md == 8) {
      this.context.setIcon(
          getIcon(124, md),
          getIcon(125, md),
          getIcon(120, md),
          getIcon(120, md),
          getIcon(120, md),
          getIcon(120, md));
    } else if (md == 10) {
      this.context.setIcon(
          getIcon(102, md),
          getIcon(103, md),
          getIcon(106, md),
          getIcon(106, md),
          getIcon(104, md),
          getIcon(104, md));
    } else if (md == 12) {
      this.context.setIcon(
          getIcon(48, md),
          getIcon(164, md),
          getIcon(167, md),
          getIcon(167, md),
          getIcon(166, md),
          getIcon(166, md));
    } else if (md == 13) {
      this.context.setIcon(
          getIcon(172, md),
          getIcon(168, md),
          getIcon(171, md),
          getIcon(171, md),
          getIcon(170, md),
          getIcon(170, md));
    } else if (md == 14) {
      this.context.setIcon(
          getIcon(58, md),
          getIcon(89, md),
          getIcon(91, md),
          getIcon(91, md),
          getIcon(90, md),
          getIcon(90, md));
    } else if (md == 15) {
      this.context.setIcon(
          getIcon(58, md),
          getIcon(89, md),
          getIcon(93, md),
          getIcon(93, md),
          getIcon(90, md),
          getIcon(90, md));
    } else {
      this.context.setIcon(
          getIcon(58, md),
          getIcon(57, md),
          getIcon(61, md),
          getIcon(61, md),
          getIcon(61, md),
          getIcon(61, md));
    }

    this.context.renderBox(63, 0.0D, 0.0D, 0.0D, 1.0D, 1.0D, 1.0D);
    tessellator.draw();
    // RenderLib.unbindTexture();
    this.context.useNormal = false;
  }