Refactoring

Type-safety

Minor performance improvements
This commit is contained in:
thatsIch
2014-11-28 04:36:46 +01:00
parent 9fae9d1ec0
commit 2243c5a188
87 changed files with 899 additions and 730 deletions
@@ -18,6 +18,10 @@
package appeng.client.render.blocks;
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.FontRenderer;
import net.minecraft.client.renderer.GLAllocation;
@@ -27,9 +31,6 @@ import net.minecraft.client.renderer.Tessellator;
import net.minecraft.item.ItemStack;
import net.minecraftforge.common.util.ForgeDirection;
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
import appeng.api.storage.data.IAEItemStack;
import appeng.block.AEBaseBlock;
import appeng.client.ClientHelper;
@@ -176,11 +177,11 @@ public class RenderBlockCraftingCPUMonitor extends RenderBlockCraftingCPU
String msg = Long.toString( qty );
if ( qty > 1000000000 )
msg = Long.toString( qty / 1000000000 ) + "B";
msg = Long.toString( qty / 1000000000 ) + 'B';
else if ( qty > 1000000 )
msg = Long.toString( qty / 1000000 ) + "M";
msg = Long.toString( qty / 1000000 ) + 'M';
else if ( qty > 9999 )
msg = Long.toString( qty / 1000 ) + "K";
msg = Long.toString( qty / 1000 ) + 'K';
FontRenderer fr = Minecraft.getMinecraft().fontRenderer;
int width = fr.getStringWidth( msg );