Jump to content

  • Curse Sites
Become a Premium Member! Help
Latest News Article

Need Help! How to disable autosave?


  • Please log in to reply
1 reply to this topic

#1

Alexander4D

Posted 03 February 2012 - 11:41 AM

I need to disable so the map never saves, even when clicked 'Save and Quit to Main Menu' (just to bring player to main menu)

GuiIngameMenu.java:
package net.minecraft.src;

import java.util.List;
import net.minecraft.client.Minecraft;

public class GuiIngameMenu extends GuiScreen
{


	public GuiIngameMenu()
	{

	}

	public void initGui()
	{

		controlList.clear();
		byte byte0 = -16;
		controlList.add(new GuiButton(4, width / 2 - 100, height / 4 + 56 + byte0, StatCollector.translateToLocal("menu.returnToGame")));
		controlList.add(new GuiButton(1, width / 2 - 100, height / 4 + 80 + byte0, StatCollector.translateToLocal("menu.returnToMenu")));
	}

	protected void actionPerformed(GuiButton guibutton)
	{
		if (guibutton.id == 0)
		{
			mc.displayGuiScreen(new GuiOptions(this, mc.gameSettings));
		}
		if (guibutton.id == 1)
		{
			mc.statFileWriter.readStat(StatList.leaveGameStat, 1);
			if (mc.isMultiplayerWorld())
			{
				mc.theWorld.sendQuittingDisconnectingPacket();
			}
			mc.changeWorld1(null);
			mc.displayGuiScreen(new GuiMainMenu());
		}
		if (guibutton.id == 4)
		{
			mc.displayGuiScreen(null);
			mc.setIngameFocus();
		}
		if (guibutton.id == 5)
		{
			mc.displayGuiScreen(new GuiAchievements(mc.statFileWriter));
		}
		if (guibutton.id == 6)
		{
			mc.displayGuiScreen(new GuiStats(this, mc.statFileWriter));
		}
	}

	public void updateScreen()
	{
		super.updateScreen();

	}

	public void drawScreen(int i, int j, float f)
	{
		drawDefaultBackground();

		drawCenteredString(fontRenderer, "Game menu", width / 2, 40, 0xffffff);
		super.drawScreen(i, j, f);
	}
}

I don't know what to change here to disable saving

Register or log in to remove.

#2

Alexander4D

Posted 03 February 2012 - 12:06 PM

nevermind, found the solution (in World.java delete every 'saveWorld')