Hi!
I made a Gui screen for MC1.3.2, I think I write it good, but only the textfield dont want to work.
You need to travel to the past if you want to help me.
Here's the GuiScreen file:
@SideOnly(Side.CLIENT)
public class GuiLogin extends GuiScreen
{
private final GuiScreen parentScreen;
private GuiTextField username;
public void initGui()
{
super.initGui();
username = new GuiTextField(this.fontRenderer, this.width / 2, this.height / 2, 100, 20);
this.username.setTextColor(-1);
this.username.setMaxStringLength(10);
this.username.setEnableBackgroundDrawing(true);
this.username.setVisible(true);
}
public GuiLogin(GuiScreen par1GuiScreen)
{
this.parentScreen = par1GuiScreen;
}
@Override
public void drawScreen(int x, int y, float f)
{
this.initGui();
this.username.drawTextBox();
this.BackGround();
super.drawScreen(x, y, f);
}
private void BackGround()
{
final int xSizeOfTexture = 176;
final int ySizeOfTexture = 88;
drawDefaultBackground();
int var4 = this.mc.renderEngine.getTexture("/mmod/media/default.png");
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
this.mc.renderEngine.bindTexture(var4);
int posX = (this.width - xSizeOfTexture) / 2;
int posY = (this.height - ySizeOfTexture) / 2;
drawTexturedModalRect(posX, posY, 0, 0, xSizeOfTexture, ySizeOfTexture);
}
}
Please help me!