mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-22 21:20:12 +00:00
115 lines
4.3 KiB
Diff
115 lines
4.3 KiB
Diff
--- ../src-base/minecraft/net/minecraft/client/Minecraft.java
|
|
+++ ../src-work/minecraft/net/minecraft/client/Minecraft.java
|
|
@@ -1,6 +1,9 @@
|
|
package net.minecraft.client;
|
|
|
|
import com.google.common.collect.Lists;
|
|
+
|
|
+import cpw.mods.fml.client.FMLClientHandler;
|
|
+import cpw.mods.fml.common.FMLCommonHandler;
|
|
import cpw.mods.fml.relauncher.Side;
|
|
import cpw.mods.fml.relauncher.SideOnly;
|
|
import io.netty.util.concurrent.GenericFutureListener;
|
|
@@ -146,6 +149,8 @@
|
|
import org.lwjgl.opengl.PixelFormat;
|
|
import org.lwjgl.util.glu.GLU;
|
|
|
|
+import com.google.common.collect.MapDifference;
|
|
+
|
|
@SideOnly(Side.CLIENT)
|
|
public class Minecraft implements IPlayerUsage
|
|
{
|
|
@@ -448,7 +453,7 @@
|
|
this.field_110451_am = new SimpleReloadableResourceManager(this.field_110452_an);
|
|
this.field_135017_as = new LanguageManager(this.field_110452_an, this.field_71474_y.field_74363_ab);
|
|
this.field_110451_am.func_110542_a(this.field_135017_as);
|
|
- this.func_110436_a();
|
|
+ FMLClientHandler.instance().beginMinecraftLoading(this, this.field_110449_ao, this.field_110451_am);
|
|
this.field_71446_o = new TextureManager(this.field_110451_am);
|
|
this.field_110451_am.func_110542_a(this.field_71446_o);
|
|
this.field_147127_av = new SoundHandler(this.field_110451_am, this.field_71474_y);
|
|
@@ -508,12 +513,13 @@
|
|
this.field_71446_o.func_130088_a(TextureMap.field_110576_c, new TextureMap(1, "textures/items"));
|
|
GL11.glViewport(0, 0, this.field_71443_c, this.field_71440_d);
|
|
this.field_71452_i = new EffectRenderer(this.field_71441_e, this.field_71446_o);
|
|
+ FMLClientHandler.instance().finishMinecraftLoading();
|
|
this.func_71361_d("Post startup");
|
|
this.field_71456_v = new GuiIngame(this);
|
|
|
|
if (this.field_71475_ae != null)
|
|
{
|
|
- this.func_147108_a(new GuiConnecting(new GuiMainMenu(), this, this.field_71475_ae, this.field_71477_af));
|
|
+ FMLClientHandler.instance().connectToServerAtStartup(this.field_71475_ae, this.field_71477_af);
|
|
}
|
|
else
|
|
{
|
|
@@ -527,6 +533,7 @@
|
|
this.func_71352_k();
|
|
}
|
|
|
|
+ FMLClientHandler.instance().onInitializationComplete();
|
|
Display.setVSyncEnabled(this.field_71474_y.field_74352_v);
|
|
}
|
|
|
|
@@ -916,9 +923,11 @@
|
|
|
|
if (!this.field_71454_w)
|
|
{
|
|
+ FMLCommonHandler.instance().onRenderTickStart(this.field_71428_T.field_74281_c);
|
|
this.field_71424_I.func_76318_c("gameRenderer");
|
|
this.field_71460_t.func_78480_b(this.field_71428_T.field_74281_c);
|
|
this.field_71424_I.func_76319_b();
|
|
+ FMLCommonHandler.instance().onRenderTickEnd(this.field_71428_T.field_74281_c);
|
|
}
|
|
|
|
GL11.glFlush();
|
|
@@ -1496,6 +1505,8 @@
|
|
--this.field_71467_ac;
|
|
}
|
|
|
|
+ FMLCommonHandler.instance().onPreClientTick();
|
|
+
|
|
this.field_71424_I.func_76320_a("gui");
|
|
|
|
if (!this.field_71445_n)
|
|
@@ -1646,6 +1657,7 @@
|
|
this.field_71462_r.func_146274_d();
|
|
}
|
|
}
|
|
+ FMLCommonHandler.instance().fireMouseInput();
|
|
}
|
|
|
|
if (this.field_71429_W > 0)
|
|
@@ -1787,6 +1799,7 @@
|
|
}
|
|
}
|
|
}
|
|
+ FMLCommonHandler.instance().fireKeyInput();
|
|
}
|
|
}
|
|
|
|
@@ -1978,12 +1991,15 @@
|
|
this.field_71453_ak.func_74428_b();
|
|
}
|
|
|
|
+ FMLCommonHandler.instance().onPostClientTick();
|
|
+
|
|
this.field_71424_I.func_76319_b();
|
|
this.field_71423_H = func_71386_F();
|
|
}
|
|
|
|
public void func_71371_a(String p_71371_1_, String p_71371_2_, WorldSettings p_71371_3_)
|
|
{
|
|
+ FMLClientHandler.instance().startIntegratedServer(p_71371_1_, p_71371_2_, p_71371_3_);
|
|
this.func_71403_a((WorldClient)null);
|
|
System.gc();
|
|
ISaveHandler isavehandler = this.field_71469_aa.func_75804_a(p_71371_1_, false);
|
|
@@ -2094,6 +2110,7 @@
|
|
this.field_110448_aq.func_148529_f();
|
|
this.func_71351_a((ServerData)null);
|
|
this.field_71455_al = false;
|
|
+ FMLClientHandler.instance().handleClientWorldClosing(this.field_71441_e);
|
|
}
|
|
|
|
this.field_147127_av.func_147690_c();
|