Patch some GUIs. We're gonna add some basic mod gui config support.

This commit is contained in:
Christian 2013-12-16 11:48:39 -05:00
parent 26056619a9
commit 69ce79e1d7
2 changed files with 37 additions and 0 deletions

View File

@ -0,0 +1,24 @@
--- ../src-base/minecraft/net/minecraft/client/gui/GuiButton.java
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiButton.java
@@ -23,6 +23,7 @@
public boolean field_146125_m;
protected boolean field_146123_n;
private static final String __OBFID = "CL_00000668";
+ public int packedFGColour;
public GuiButton(int p_i1020_1_, int p_i1020_2_, int p_i1020_3_, String p_i1020_4_)
{
@@ -76,8 +77,12 @@
this.func_146119_b(p_146112_1_, p_146112_2_, p_146112_3_);
int l = 14737632;
- if (!this.field_146124_l)
+ if (packedFGColour != 0)
{
+ l = packedFGColour;
+ }
+ else if (!this.field_146124_l)
+ {
l = 10526880;
}
else if (this.field_146123_n)

View File

@ -0,0 +1,13 @@
--- ../src-base/minecraft/net/minecraft/client/gui/GuiIngameMenu.java
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiIngameMenu.java
@@ -29,8 +29,9 @@
this.field_146292_n.add(new GuiButton(4, this.field_146294_l / 2 - 100, this.field_146295_m / 4 + 24 + b0, I18n.func_135052_a("menu.returnToGame", new Object[0])));
this.field_146292_n.add(new GuiButton(0, this.field_146294_l / 2 - 100, this.field_146295_m / 4 + 96 + b0, 98, 20, I18n.func_135052_a("menu.options", new Object[0])));
+ this.field_146292_n.add(new GuiButton(12, this.field_146294_l / 2 + 2, this.field_146295_m / 4 + 96 + b0, 98, 20, "Mod Options"));
GuiButton guibutton;
- this.field_146292_n.add(guibutton = new GuiButton(7, this.field_146294_l / 2 + 2, this.field_146295_m / 4 + 96 + b0, 98, 20, I18n.func_135052_a("menu.shareToLan", new Object[0])));
+ this.field_146292_n.add(guibutton = new GuiButton(7, this.field_146294_l / 2 - 100, this.field_146295_m / 4 + 72 + b0, 200, 20, I18n.func_135052_a("menu.shareToLan", new Object[0])));
this.field_146292_n.add(new GuiButton(5, this.field_146294_l / 2 - 100, this.field_146295_m / 4 + 48 + b0, 98, 20, I18n.func_135052_a("gui.achievements", new Object[0])));
this.field_146292_n.add(new GuiButton(6, this.field_146294_l / 2 + 2, this.field_146295_m / 4 + 48 + b0, 98, 20, I18n.func_135052_a("gui.stats", new Object[0])));
guibutton.field_146124_l = this.field_146297_k.func_71356_B() && !this.field_146297_k.func_71401_C().func_71344_c();