Add stub ChunkLoadingRenderGlobal for 1.7.10

Allows us to get rid of all preprocessor guards around its usages.
This commit is contained in:
Jonas Herzig
2021-02-23 12:01:15 +01:00
parent c729654f04
commit ab5b101f96
5 changed files with 14 additions and 22 deletions

View File

@@ -17,6 +17,7 @@ import com.replaymod.render.events.ReplayRenderCallback;
import com.replaymod.render.frame.BitmapFrame;
import com.replaymod.render.gui.GuiRenderingDone;
import com.replaymod.render.gui.GuiVideoRenderer;
import com.replaymod.render.hooks.ChunkLoadingRenderGlobal;
import com.replaymod.render.metadata.MetadataInjector;
import com.replaymod.render.mixin.WorldRendererAccessor;
import com.replaymod.replay.ReplayHandler;
@@ -57,7 +58,6 @@ import java.util.concurrent.CompletableFuture;
//#endif
//#if MC>=10800
import com.replaymod.render.hooks.ChunkLoadingRenderGlobal;
import static com.mojang.blaze3d.platform.GlStateManager.*;
//#else
//$$ import com.replaymod.replay.gui.screen.GuiOpeningReplay;
@@ -95,9 +95,7 @@ public class VideoRenderer implements RenderInfo {
private TimelinePlayer timelinePlayer;
private Future<Void> timelinePlayerFuture;
//#if MC>=10800
private ChunkLoadingRenderGlobal chunkLoadingRenderGlobal;
//#endif
//#if MC<10800
//$$ private GuiOpeningReplay guiOpeningReplay;
//#endif
@@ -371,9 +369,7 @@ public class VideoRenderer implements RenderInfo {
//$$ gui.toMinecraft().setWorldAndResolution(mc, scaled.getScaledWidth(), scaled.getScaledHeight());
//#endif
//#if MC>=10800
chunkLoadingRenderGlobal = new ChunkLoadingRenderGlobal(mc.worldRenderer);
//#endif
// Set up our own framebuffer to render the GUI to
guiFramebuffer = new Framebuffer(displayWidth, displayHeight, true
@@ -408,11 +404,7 @@ public class VideoRenderer implements RenderInfo {
mc.options.setSoundVolume(entry.getKey(), entry.getValue());
}
mc.openScreen(null);
//#if MC>=10800
if (chunkLoadingRenderGlobal != null) {
chunkLoadingRenderGlobal.uninstall();
}
//#endif
chunkLoadingRenderGlobal.uninstall();
if (!hasFailed() && cameraPathExporter != null) {
try {