Package net.minecraft.client.gui

Examples of net.minecraft.client.gui.FontRenderer.drawString()


        }
       
        var17.drawString("ID: " + String.valueOf(Item.getIdFromItem(item)), -var17.getStringWidth("ID: " + String.valueOf(Item.getIdFromItem(item))) / 2, 0 * 10 - 4 * 5, 0);
        ModuleCrafter logisticsMod=cpipe.getLogisticsModule();
        if(logisticsMod.satelliteId != 0) {
          var17.drawString("Sat ID: " + String.valueOf(logisticsMod.satelliteId), -var17.getStringWidth("Sat ID: " + String.valueOf(logisticsMod.satelliteId)) / 2, 1 * 10 - 4 * 5, 0);
        }
      } else {
        GL11.glRotatef(-180.0F, 1.0F, 0.0F, 0.0F);
        GL11.glTranslatef(0.5F, +0.08F, 0.0F);
        GL11.glScalef(1.0F / 90.0F, 1.0F / 90.0F, 1.0F / 90.0F);
View Full Code Here


        name = "Empty";
      }
     
      name = renderer.cut(name, var17);
     
      var17.drawString(name, -var17.getStringWidth(name) / 2 - 15, 3 * 10 - 4 * 5, 0);
     
      GL11.glDepthMask(true);
      GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
    }
  }
View Full Code Here

          try {
            name = item.getUnlocalizedName();
          } catch(Exception e1) {}
        }
       
        var17.drawString("ID: " + String.valueOf(Item.getIdFromItem(item)), -var17.getStringWidth("ID: " + String.valueOf(Item.getIdFromItem(item))) / 2, 0 * 10 - 4 * 5, 0);
        String displayAmount = StringUtil.getFormatedStackSize(amount);
        var17.drawString("Amount:", -var17.getStringWidth("Amount:") / 2, 1 * 10 - 4 * 5, 0);
        var17.drawString(String.valueOf(displayAmount), -var17.getStringWidth(String.valueOf(displayAmount)) / 2, 2 * 10 - 4 * 5, 0);
      } else {
        GL11.glRotatef(-180.0F, 1.0F, 0.0F, 0.0F);
View Full Code Here

          } catch(Exception e1) {}
        }
       
        var17.drawString("ID: " + String.valueOf(Item.getIdFromItem(item)), -var17.getStringWidth("ID: " + String.valueOf(Item.getIdFromItem(item))) / 2, 0 * 10 - 4 * 5, 0);
        String displayAmount = StringUtil.getFormatedStackSize(amount);
        var17.drawString("Amount:", -var17.getStringWidth("Amount:") / 2, 1 * 10 - 4 * 5, 0);
        var17.drawString(String.valueOf(displayAmount), -var17.getStringWidth(String.valueOf(displayAmount)) / 2, 2 * 10 - 4 * 5, 0);
      } else {
        GL11.glRotatef(-180.0F, 1.0F, 0.0F, 0.0F);
        GL11.glTranslatef(0.5F, +0.08F, 0.0F);
        GL11.glScalef(1.0F / 90.0F, 1.0F / 90.0F, 1.0F / 90.0F);
View Full Code Here

        }
       
        var17.drawString("ID: " + String.valueOf(Item.getIdFromItem(item)), -var17.getStringWidth("ID: " + String.valueOf(Item.getIdFromItem(item))) / 2, 0 * 10 - 4 * 5, 0);
        String displayAmount = StringUtil.getFormatedStackSize(amount);
        var17.drawString("Amount:", -var17.getStringWidth("Amount:") / 2, 1 * 10 - 4 * 5, 0);
        var17.drawString(String.valueOf(displayAmount), -var17.getStringWidth(String.valueOf(displayAmount)) / 2, 2 * 10 - 4 * 5, 0);
      } else {
        GL11.glRotatef(-180.0F, 1.0F, 0.0F, 0.0F);
        GL11.glTranslatef(0.5F, +0.08F, 0.0F);
        GL11.glScalef(1.0F / 90.0F, 1.0F / 90.0F, 1.0F / 90.0F);
        name = "Empty";
View Full Code Here

        name = "Empty";
      }
     
      name = renderer.cut(name, var17);
     
      var17.drawString(name, -var17.getStringWidth(name) / 2 - 15, 3 * 10 - 4 * 5, 0);
     
      GL11.glDepthMask(true);
      GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
    }
  }
View Full Code Here

      msg = Long.toString( qty / 1000 ) + "K";

    FontRenderer fr = Minecraft.getMinecraft().fontRenderer;
    int width = fr.getStringWidth( msg );
    GL11.glTranslatef( -0.5f * width, 0.0f, -1.0f );
    fr.drawString( msg, 0, 0, 0 );

    GL11.glPopAttrib();
  }

}
View Full Code Here

        CachedGrindStoneRecipe cachedRecipe = (CachedGrindStoneRecipe) cr;
        if ( cachedRecipe.hasOptional )
        {
          FontRenderer fr = Minecraft.getMinecraft().fontRenderer;
          int width = fr.getStringWidth( cachedRecipe.Chance );
          fr.drawString( cachedRecipe.Chance, (168 - width) / 2, 5, 0 );
        }
        else
        {
          FontRenderer fr = Minecraft.getMinecraft().fontRenderer;
          int width = fr.getStringWidth( GuiText.NoSecondOutput.getLocal() );
View Full Code Here

        }
        else
        {
          FontRenderer fr = Minecraft.getMinecraft().fontRenderer;
          int width = fr.getStringWidth( GuiText.NoSecondOutput.getLocal() );
          fr.drawString( GuiText.NoSecondOutput.getLocal(), (168 - width) / 2, 5, 0 );
        }
      }
    }
  }
View Full Code Here

      msg = Long.toString( qty / 1000 ) + "K";

    FontRenderer fr = Minecraft.getMinecraft().fontRenderer;
    int width = fr.getStringWidth( msg );
    GL11.glTranslatef( -0.5f * width, 0.0f, -1.0f );
    fr.drawString( msg, 0, 0, 0 );

    GL11.glPopAttrib();
  }

  @Override
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.