Save modifications of downloaded replays to separate file
This commit is contained in:
@@ -136,7 +136,10 @@ public class ReplayModReplay {
|
||||
}
|
||||
|
||||
public void startReplay(File file) throws IOException {
|
||||
ReplayFile replayFile = new ZipReplayFile(new ReplayStudio(), file);
|
||||
startReplay(new ZipReplayFile(new ReplayStudio(), file));
|
||||
}
|
||||
|
||||
public void startReplay(ReplayFile replayFile) throws IOException {
|
||||
replayHandler = new ReplayHandler(replayFile, true);
|
||||
}
|
||||
|
||||
|
||||
@@ -99,12 +99,12 @@ public class GuiHandler {
|
||||
if (event.gui instanceof GuiIngameMenu && mod.getReplayHandler() != null) {
|
||||
if (event.button.id == BUTTON_EXIT_REPLAY) {
|
||||
event.button.enabled = false;
|
||||
mc.displayGuiScreen(new GuiMainMenu());
|
||||
try {
|
||||
mod.getReplayHandler().endReplay();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
mc.displayGuiScreen(new GuiMainMenu());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user