aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/makamys/neodymium/mixin/MixinRenderGlobal_OptiFine.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/makamys/neodymium/mixin/MixinRenderGlobal_OptiFine.java')
-rw-r--r--src/main/java/makamys/neodymium/mixin/MixinRenderGlobal_OptiFine.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/main/java/makamys/neodymium/mixin/MixinRenderGlobal_OptiFine.java b/src/main/java/makamys/neodymium/mixin/MixinRenderGlobal_OptiFine.java
index e79f4b7..8d491d0 100644
--- a/src/main/java/makamys/neodymium/mixin/MixinRenderGlobal_OptiFine.java
+++ b/src/main/java/makamys/neodymium/mixin/MixinRenderGlobal_OptiFine.java
@@ -3,6 +3,7 @@ package makamys.neodymium.mixin;
import java.nio.IntBuffer;
import org.lwjgl.opengl.GL11;
+import org.spongepowered.asm.mixin.Dynamic;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Redirect;
@@ -15,7 +16,12 @@ import net.minecraft.client.renderer.RenderGlobal;
abstract class MixinRenderGlobal_OptiFine {
// for OptiFine's Fast Render option
- @Redirect(method = "renderSortedRenderersFast", at = @At(value = "INVOKE", target = "Lorg/lwjgl/opengl/GL11;glCallLists(Ljava/nio/IntBuffer;)V"), remap=false)
+ @Dynamic
+ @Redirect(method = "renderSortedRenderersFast",
+ at = @At(value = "INVOKE",
+ target = "Lorg/lwjgl/opengl/GL11;glCallLists(Ljava/nio/IntBuffer;)V"),
+ remap=false,
+ require = 1)
private void redirectRenderAllRenderLists(IntBuffer buffer) {
if(Neodymium.shouldRenderVanillaWorld()) {
GL11.glCallLists(buffer);