Tick only when there's a world
This commit is contained in:
parent
caa5384552
commit
fdd80dad80
1 changed files with 18 additions and 11 deletions
|
@ -194,9 +194,11 @@ public class FMLClientHandler implements IFMLSidedHandler
|
|||
*/
|
||||
public void onPreWorldTick()
|
||||
{
|
||||
FMLCommonHandler.instance().worldTickStart();
|
||||
if (client.field_6313_p!=null && client.field_6324_e!=null) {
|
||||
FMLCommonHandler.instance().tickStart(TickType.WORLDGUI, 0.0f, client.field_6313_p);
|
||||
if (client.field_6324_e != null) {
|
||||
FMLCommonHandler.instance().worldTickStart();
|
||||
if (client.field_6313_p !=null) {
|
||||
FMLCommonHandler.instance().tickStart(TickType.WORLDGUI, 0.0f, client.field_6313_p);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -205,25 +207,30 @@ public class FMLClientHandler implements IFMLSidedHandler
|
|||
*/
|
||||
public void onPostWorldTick()
|
||||
{
|
||||
FMLCommonHandler.instance().worldTickEnd();
|
||||
if (client.field_6313_p!=null && client.field_6324_e!=null) {
|
||||
FMLCommonHandler.instance().tickEnd(TickType.WORLDGUI, 0.0f, client.field_6313_p);
|
||||
if (client.field_6324_e != null) {
|
||||
FMLCommonHandler.instance().worldTickEnd();
|
||||
if (client.field_6313_p!=null) {
|
||||
FMLCommonHandler.instance().tickEnd(TickType.WORLDGUI, 0.0f, client.field_6313_p);
|
||||
}
|
||||
}
|
||||
|
||||
public void onRenderTickStart(float partialTickTime)
|
||||
{
|
||||
if (client.field_6324_e != null) {
|
||||
FMLCommonHandler.instance().tickStart(TickType.RENDER, partialTickTime);
|
||||
if (client.field_6313_p!=null && client.field_6324_e!=null) {
|
||||
FMLCommonHandler.instance().tickStart(TickType.GUI, partialTickTime, client.field_6313_p);
|
||||
if (client.field_6324_e!=null) {
|
||||
FMLCommonHandler.instance().tickStart(TickType.GUI, partialTickTime, client.field_6313_p);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void onRenderTickEnd(float partialTickTime)
|
||||
{
|
||||
FMLCommonHandler.instance().tickEnd(TickType.RENDER, partialTickTime);
|
||||
if (client.field_6313_p!=null && client.field_6324_e!=null) {
|
||||
FMLCommonHandler.instance().tickEnd(TickType.GUI, partialTickTime, client.field_6313_p);
|
||||
if (client.field_6324_e != null) {
|
||||
FMLCommonHandler.instance().tickEnd(TickType.RENDER, partialTickTime);
|
||||
if (client.field_6324_e!=null) {
|
||||
FMLCommonHandler.instance().tickEnd(TickType.GUI, partialTickTime, client.field_6313_p);
|
||||
}
|
||||
}
|
||||
}
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue