From 50d706796801abf6e9cec1c9cb7e664bde73ab05 Mon Sep 17 00:00:00 2001 From: makamys Date: Mon, 24 May 2021 13:55:02 +0200 Subject: Tweak fog rendering, skybox edge is no longer visible --- src/main/java/makamys/lodmod/mixin/MixinEntityRenderer.java | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/main/java/makamys/lodmod/mixin/MixinEntityRenderer.java') diff --git a/src/main/java/makamys/lodmod/mixin/MixinEntityRenderer.java b/src/main/java/makamys/lodmod/mixin/MixinEntityRenderer.java index dda56a4..7f5aed0 100644 --- a/src/main/java/makamys/lodmod/mixin/MixinEntityRenderer.java +++ b/src/main/java/makamys/lodmod/mixin/MixinEntityRenderer.java @@ -29,11 +29,7 @@ abstract class MixinEntityRenderer { @Inject(method = "setupFog", at = @At(value = "RETURN")) private void afterSetupFog(int mode, float alpha, CallbackInfo ci) { if(LODMod.isActive()) { - EntityLivingBase entity = Minecraft.getMinecraft().renderViewEntity; - if(LODMod.fogEventWasPosted && mode >= 0 && !Minecraft.getMinecraft().theWorld.provider.doesXZShowFog((int)entity.posX, (int)entity.posZ)) { - GL11.glFogf(GL11.GL_FOG_START, farPlaneDistance * 0.2f); - GL11.glFogf(GL11.GL_FOG_END, farPlaneDistance); - } + LODMod.renderer.afterSetupFog(mode, alpha, farPlaneDistance); } } } -- cgit