Jump to content

Recommended Posts

Posted

I'm trying to make a Buildcraft addon. The buidcraft is in my project as a Jar. I have some classes that extend buidcraft classes. When I recompile, I get many errors:

 

  Reveal hidden contents

 

package finetechnology.buildcraftaddon;

import org.lwjgl.opengl.GL11;

import net.java.games.input.Keyboard;
import net.minecraft.client.gui.GuiButton;
import net.minecraft.client.gui.GuiScreen;
import net.minecraft.client.gui.GuiTextField;
import net.minecraft.client.gui.inventory.GuiContainer;
import net.minecraft.inventory.IInventory;
import buildcraft.core.gui.BuildCraftContainer;
import buildcraft.core.gui.GuiBuildCraft;
import buildcraft.transport.TileGenericPipe;

public class GUItextPipe extends GuiBuildCraft {


public GUItextPipe(BuildCraftContainer container, IInventory inventory) {
	super(new ContainerTextPipe(0), inventory);
	// TODO Auto-generated constructor stub
}
String [] filters;
byte yOffset=33;
byte stringHeight=18;
//	PipeLogicText filter;
byte xBetween=40;
//	GuiTextField addFilters[]=new gui;
GuiTextField filter;
String filterText;
@Override
public void initGui() {
	super.initGui();
	String text="Add filter";
	filter=new GuiTextField(fontRenderer,width/2-width/12,3,width/6,16);
	org.lwjgl.input.Keyboard.enableRepeatEvents(true);

//		GuiButton add=new GuiButton(0, xBetween,13, text.length(), stringHeight, tezt);

	for (byte side=0;side<6; side++)
	{
		String buttontext="Add here";
		buttonList.add(new GuiButton(side,3+(width/6)*side,23,fontRenderer.getStringWidth(buttontext)+6,18,buttontext));
	}
}

@Override
public void drawScreen(int arg0, int arg1, float arg2) {
	super.drawScreen(arg0, arg1, arg2);
	filter.drawTextBox();
//		filter.
}
@Override
protected void drawGuiContainerBackgroundLayer(float f, int i, int j) {
	this.
	drawVerticalLine(guiLeft,guiTop+ySize, guiTop, -9408400);
	drawVerticalLine(guiLeft+xSize,guiTop+ySize,guiTop,-9408400);
	drawHorizontalLine(guiLeft,guiLeft+xSize,guiTop, -9408400);

}
@Override
protected void mouseClicked(int par1, int par2, int mouseButton) {
	super.mouseClicked(par1, par2, mouseButton);
	filter.mouseClicked(par1,par2,mouseButton);
}
@Override
protected void keyTyped(char par1, int par2) {
	if(filter.textboxKeyTyped(par1,par2))
	{
		filterText=filter.getText();
	}	
}
@Override
public void onGuiClosed() {
	// TODO Auto-generated method stub
	super.onGuiClosed();
	org.lwjgl.input.Keyboard.enableRepeatEvents(false);
}
}

Posted

The MCP recompiler doesn't know that you're using a .jar. Everything that has to be recompiled should be in the mcp/src folder. So I think the solution would be to download the dev version from the Buildcraft Github, and add it to the mcp/src folder. Yes, this will output the Buildcraft mod as well in the mcp/reobf folder, but you can just leave it there.

Author of PneumaticCraft, MineChess, Minesweeper Mod and Sokoban Mod. Visit www.minemaarten.com to take a look at them.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.