From 5cb4c6e24033cf337812390d99a6817d24d21eab Mon Sep 17 00:00:00 2001 From: Foghrye4 Date: Sun, 12 Feb 2017 20:43:03 +0300 Subject: Removed explosion radius limitations. Explosion calculation optimized (reduced memory usage). One more detonator and explosive pack recipe. GT6 recipes for both chemical reactors and cryogenic distiller. Max stack size of muffle furnace is limited to 32. A lot of old features are removed. --- ihl/guidebook/IHLGuidebookGui.java | 276 ------------------------------------- 1 file changed, 276 deletions(-) delete mode 100644 ihl/guidebook/IHLGuidebookGui.java (limited to 'ihl/guidebook/IHLGuidebookGui.java') diff --git a/ihl/guidebook/IHLGuidebookGui.java b/ihl/guidebook/IHLGuidebookGui.java deleted file mode 100644 index 316660b..0000000 --- a/ihl/guidebook/IHLGuidebookGui.java +++ /dev/null @@ -1,276 +0,0 @@ -package ihl.guidebook; - -import java.io.IOException; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import org.lwjgl.opengl.GL11; -import org.xml.sax.SAXException; - -import net.minecraft.client.gui.GuiButton; -import net.minecraft.client.gui.inventory.GuiContainer; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraft.util.StatCollector; -import ihl.IHLMod; -import ihl.datanet.GuiInvisibleButton; -import ihl.utils.IHLRenderUtils; - -public class IHLGuidebookGui extends GuiContainer -{ - public IHLGuidebookContainer container; - private static final ResourceLocation background = new ResourceLocation("ihl", "textures/gui/GUIGuidebook.png"); - public Map linksCoordinatesMap = new HashMap(); - private String title; - private String[] localisedContent=new String[2];;// By text block and row - private ResourceLocation[] resourceLocationCache = new ResourceLocation[16];//By section number - private int currentSection=0; - private final int titleX=25; - private final int titleY=7; - private final int textBlockWidth=104; - private final int textBlockX1=20; - private final int textBlockY1=38; - private final int textBlockX2=130; - private final int textBlockY2=5; - private final int textBlockMaxY=200; - private int stringHeight=10; - private int textRowInNextPage=0; - private int textBlockInNextPage=0; - private int[] textRowStart=new int[2]; - private int textBlockStart=0; - private int pictureWidth; - private int pictureHeight; - private int maxSection=0; - - public IHLGuidebookGui(IHLGuidebookContainer container1) { - super(container1); - this.container = container1; - this.xSize=this.container.xSize; - this.ySize=this.container.ySize; - } - - @Override - public void initGui() - { - super.initGui(); - int x = (width - xSize) / 2; - int y = (height - ySize) / 2; - new GuiInvisibleButton(0, x, y, xSize/2, 162, linksCoordinatesMap, buttonList); - new GuiInvisibleButton(1, x+xSize/2, y, xSize/2, 162, linksCoordinatesMap, buttonList); - this.clear(); - try { - IHLMod.xmlparser.setupGuidebookGUI(this, 0); - } catch (SAXException e) { - e.printStackTrace(); - } catch (IOException e) { - e.printStackTrace(); - } - } - - @Override - public void actionPerformed(GuiButton button) - { - super.actionPerformed(button); - switch(button.id) - { - case 0: - currentSection--; - if(currentSection<0) - { - currentSection=this.maxSection; - } - this.textBlockStart=0; - this.textRowStart[0]=0; - this.textRowStart[1]=0; - break; - case 1: - if(textRowInNextPage==0 && textBlockInNextPage==0) - { - currentSection++; - this.textBlockStart=0; - this.textRowStart[0]=0; - this.textRowStart[1]=0; - } - else - { - this.textBlockStart=textBlockInNextPage; - this.textRowStart[textBlockStart]=textRowInNextPage; - textRowInNextPage=0; - textBlockInNextPage=0; - } - break; - } - this.clear(); - try { - IHLMod.xmlparser.setupGuidebookGUI(this, currentSection); - } catch (SAXException e) { - e.printStackTrace(); - } catch (IOException e) { - e.printStackTrace(); - } - } - - public void clear() - { - for(int i=0;i splittedText = IHLRenderUtils.instance.splitStringByWidth(this.localisedContent[0], Math.round(textBlockWidth)); - for(int i1=this.textRowStart[0]; i1 < splittedText.size(); i1++) - { - yPos+=stringHeight; - if(yPos splittedText = IHLRenderUtils.instance.splitStringByWidth(this.localisedContent[1], Math.round(textBlockWidth)); - for(int i1=this.textRowStart[1]; i1 < splittedText.size(); i1++) - { - yPos+=stringHeight; - if(yPos