mirror of
https://git.zelz.net/catfoolyou/Project164.git
synced 2025-12-14 10:57:42 +00:00
Some fixes, stuck on downloading terrain
This commit is contained in:
@@ -48,11 +48,12 @@ public class ActiveRenderInfo
|
||||
/**
|
||||
* Updates the current render info and camera location based on entity look angles and 1st/3rd person view mode
|
||||
*/
|
||||
public static void updateRenderInfo(EntityPlayer par0EntityPlayer, boolean par1)
|
||||
{
|
||||
public static void updateRenderInfo(EntityPlayer par0EntityPlayer, boolean par1) {
|
||||
modelview.clear(); projection.clear();
|
||||
EaglerAdapter.glGetFloat(EaglerAdapter.GL_MODELVIEW_MATRIX, modelview);
|
||||
EaglerAdapter.glGetFloat(EaglerAdapter.GL_PROJECTION_MATRIX, projection);
|
||||
EaglerAdapter.glGetInteger(EaglerAdapter.GL_VIEWPORT, viewport);
|
||||
modelview.position(0); projection.position(0); objectCoords.position(0);
|
||||
float var2 = (float) ((viewport[0] + viewport[2]) / 2);
|
||||
float var3 = (float) ((viewport[1] + viewport[3]) / 2);
|
||||
EaglerAdapter.gluUnProject(var2, var3, 0.0F, modelview, projection, viewport, objectCoords);
|
||||
@@ -62,11 +63,11 @@ public class ActiveRenderInfo
|
||||
int var4 = par1 ? 1 : 0;
|
||||
float var5 = par0EntityPlayer.rotationPitch;
|
||||
float var6 = par0EntityPlayer.rotationYaw;
|
||||
rotationX = MathHelper.cos(var6 * (float)Math.PI / 180.0F) * (float)(1 - var4 * 2);
|
||||
rotationZ = MathHelper.sin(var6 * (float)Math.PI / 180.0F) * (float)(1 - var4 * 2);
|
||||
rotationYZ = -rotationZ * MathHelper.sin(var5 * (float)Math.PI / 180.0F) * (float)(1 - var4 * 2);
|
||||
rotationXY = rotationX * MathHelper.sin(var5 * (float)Math.PI / 180.0F) * (float)(1 - var4 * 2);
|
||||
rotationXZ = MathHelper.cos(var5 * (float)Math.PI / 180.0F);
|
||||
rotationX = MathHelper.cos(var6 * (float) Math.PI / 180.0F) * (float) (1 - var4 * 2);
|
||||
rotationZ = MathHelper.sin(var6 * (float) Math.PI / 180.0F) * (float) (1 - var4 * 2);
|
||||
rotationYZ = -rotationZ * MathHelper.sin(var5 * (float) Math.PI / 180.0F) * (float) (1 - var4 * 2);
|
||||
rotationXY = rotationX * MathHelper.sin(var5 * (float) Math.PI / 180.0F) * (float) (1 - var4 * 2);
|
||||
rotationXZ = MathHelper.cos(var5 * (float) Math.PI / 180.0F);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -85,10 +85,10 @@ public class EntityPlayerSP extends EntityPlayer
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!this.mc.statFileWriter.hasAchievementUnlocked(AchievementList.openInventory))
|
||||
/*if (!this.mc.statFileWriter.hasAchievementUnlocked(AchievementList.openInventory))
|
||||
{
|
||||
this.mc.guiAchievement.queueAchievementInformation(AchievementList.openInventory);
|
||||
}
|
||||
}*/
|
||||
|
||||
this.prevTimeInPortal = this.timeInPortal;
|
||||
|
||||
@@ -490,7 +490,7 @@ public class EntityPlayerSP extends EntityPlayer
|
||||
*/
|
||||
public void addStat(StatBase par1StatBase, int par2)
|
||||
{
|
||||
if (par1StatBase != null)
|
||||
/*if (par1StatBase != null)
|
||||
{
|
||||
if (par1StatBase.isAchievement())
|
||||
{
|
||||
@@ -510,7 +510,7 @@ public class EntityPlayerSP extends EntityPlayer
|
||||
{
|
||||
this.mc.statFileWriter.readStat(par1StatBase, par2);
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
private boolean isBlockTranslucent(int par1, int par2, int par3)
|
||||
|
||||
@@ -880,12 +880,12 @@ public class GuiContainerCreative extends InventoryEffectRenderer
|
||||
{
|
||||
if (par1GuiButton.id == 0)
|
||||
{
|
||||
this.mc.displayGuiScreen(new GuiAchievements(this.mc.statFileWriter));
|
||||
//this.mc.displayGuiScreen(new GuiAchievements(this.mc.statFileWriter));
|
||||
}
|
||||
|
||||
if (par1GuiButton.id == 1)
|
||||
{
|
||||
this.mc.displayGuiScreen(new GuiStats(this, this.mc.statFileWriter));
|
||||
//this.mc.displayGuiScreen(new GuiStats(this, this.mc.statFileWriter));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -284,7 +284,7 @@ public class GuiCreateWorld extends GuiScreen
|
||||
}
|
||||
|
||||
this.mc.launchIntegratedServer(this.folderName, this.textboxWorldName.getText().trim(), var6);
|
||||
this.mc.statFileWriter.readStat(StatList.createWorldStat, 1);
|
||||
//this.mc.statFileWriter.readStat(StatList.createWorldStat, 1);
|
||||
}
|
||||
else if (par1GuiButton.id == 3)
|
||||
{
|
||||
|
||||
@@ -46,7 +46,7 @@ public class GuiIngameMenu extends GuiScreen
|
||||
|
||||
case 1:
|
||||
par1GuiButton.enabled = false;
|
||||
this.mc.statFileWriter.readStat(StatList.leaveGameStat, 1);
|
||||
//this.mc.statFileWriter.readStat(StatList.leaveGameStat, 1);
|
||||
this.mc.theWorld.sendQuittingDisconnectingPacket();
|
||||
this.mc.loadWorld((WorldClient)null);
|
||||
this.mc.displayGuiScreen(new GuiMainMenu());
|
||||
@@ -63,11 +63,11 @@ public class GuiIngameMenu extends GuiScreen
|
||||
break;
|
||||
|
||||
case 5:
|
||||
this.mc.displayGuiScreen(new GuiAchievements(this.mc.statFileWriter));
|
||||
//this.mc.displayGuiScreen(new GuiAchievements(this.mc.statFileWriter));
|
||||
break;
|
||||
|
||||
case 6:
|
||||
this.mc.displayGuiScreen(new GuiStats(this, this.mc.statFileWriter));
|
||||
//this.mc.displayGuiScreen(new GuiStats(this, this.mc.statFileWriter));
|
||||
break;
|
||||
|
||||
case 7:
|
||||
|
||||
@@ -124,12 +124,12 @@ public class GuiInventory extends InventoryEffectRenderer
|
||||
{
|
||||
if (par1GuiButton.id == 0)
|
||||
{
|
||||
this.mc.displayGuiScreen(new GuiAchievements(this.mc.statFileWriter));
|
||||
//this.mc.displayGuiScreen(new GuiAchievements(this.mc.statFileWriter));
|
||||
}
|
||||
|
||||
if (par1GuiButton.id == 1)
|
||||
{
|
||||
this.mc.displayGuiScreen(new GuiStats(this, this.mc.statFileWriter));
|
||||
//this.mc.displayGuiScreen(new GuiStats(this, this.mc.statFileWriter));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -211,7 +211,7 @@ public class GuiSelectWorld extends GuiScreen
|
||||
if (this.mc.getSaveLoader().canLoadWorld(var2))
|
||||
{
|
||||
this.mc.launchIntegratedServer(var2, var3, (WorldSettings)null);
|
||||
this.mc.statFileWriter.readStat(StatList.loadWorldStat, 1);
|
||||
//this.mc.statFileWriter.readStat(StatList.loadWorldStat, 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -110,7 +110,7 @@ public class Minecraft
|
||||
private boolean refreshTexturePacksScheduled;
|
||||
|
||||
/** Stat file writer */
|
||||
public StatFileWriter statFileWriter;
|
||||
//public StatFileWriter statFileWriter;
|
||||
private String serverName;
|
||||
private int serverPort;
|
||||
|
||||
@@ -1486,6 +1486,7 @@ public class Minecraft
|
||||
this.effectRenderer.updateEffects();
|
||||
}
|
||||
} else if (this.myNetworkManager != null) {
|
||||
|
||||
this.myNetworkManager.processReadPackets();
|
||||
} else {
|
||||
this.entityRenderer.startup = 0;
|
||||
@@ -1609,7 +1610,7 @@ public class Minecraft
|
||||
*/
|
||||
public void loadWorld(WorldClient par1WorldClient, String par2Str) // FIX THIS SHIT
|
||||
{
|
||||
/*this.statFileWriter.syncStats();
|
||||
//this.statFileWriter.syncStats();
|
||||
|
||||
if (par1WorldClient == null)
|
||||
{
|
||||
@@ -1627,7 +1628,7 @@ public class Minecraft
|
||||
|
||||
if (this.theIntegratedServer != null)
|
||||
{
|
||||
this.theIntegratedServer.initiateShutdown();
|
||||
//this.theIntegratedServer.initiateShutdown();
|
||||
}
|
||||
|
||||
this.theIntegratedServer = null;
|
||||
@@ -1678,12 +1679,12 @@ public class Minecraft
|
||||
}
|
||||
else
|
||||
{
|
||||
this.saveLoader.flushCache();
|
||||
//this.saveLoader.flushCache();
|
||||
this.thePlayer = null;
|
||||
}
|
||||
|
||||
System.gc();
|
||||
this.systemTime = 0L;*/
|
||||
this.systemTime = 0L;
|
||||
}
|
||||
|
||||
public void setNetManager(INetworkManager nm) {
|
||||
|
||||
@@ -91,6 +91,7 @@ public class NetClientHandler extends NetHandler {
|
||||
*/
|
||||
public void processReadPackets() {
|
||||
if (this.netManager != null) {
|
||||
System.out.println("[NetClientHandler] - processReadPackets called");
|
||||
this.netManager.processReadPackets();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user