|
9 | 9 | import com.llamalad7.mixinextras.injector.ModifyReturnValue; |
10 | 10 | import com.llamalad7.mixinextras.sugar.Local; |
11 | 11 | import com.mojang.blaze3d.systems.RenderSystem; |
12 | | -import meteordevelopment.meteorclient.MixinPlugin; |
13 | 12 | import meteordevelopment.meteorclient.MeteorClient; |
| 13 | +import meteordevelopment.meteorclient.MixinPlugin; |
14 | 14 | import meteordevelopment.meteorclient.events.render.GetFovEvent; |
15 | 15 | import meteordevelopment.meteorclient.events.render.Render3DEvent; |
16 | 16 | import meteordevelopment.meteorclient.events.render.RenderAfterWorldEvent; |
|
27 | 27 | import meteordevelopment.meteorclient.utils.render.CustomBannerGuiElementRenderer; |
28 | 28 | import meteordevelopment.meteorclient.utils.render.NametagUtils; |
29 | 29 | import meteordevelopment.meteorclient.utils.render.RenderUtils; |
| 30 | +import net.irisshaders.iris.api.v0.IrisApi; |
30 | 31 | import net.minecraft.client.MinecraftClient; |
31 | 32 | import net.minecraft.client.gui.DrawContext; |
32 | 33 | import net.minecraft.client.gui.render.GuiRenderer; |
@@ -128,16 +129,15 @@ private void onRenderWorld(RenderTickCounter tickCounter, CallbackInfo ci, @Loca |
128 | 129 |
|
129 | 130 | matrices.push(); |
130 | 131 | tiltViewWhenHurt(matrices, camera.getLastTickProgress()); |
131 | | - if (client.options.getBobView().getValue()) |
132 | | - bobView(matrices, camera.getLastTickProgress()); |
| 132 | + if (client.options.getBobView().getValue()) bobView(matrices, camera.getLastTickProgress()); |
133 | 133 |
|
134 | 134 | Matrix4f inverseBob = new Matrix4f(matrices.peek().getPositionMatrix()).invert(); |
135 | 135 | RenderSystem.getModelViewStack().mul(inverseBob); |
136 | 136 | matrices.pop(); |
137 | 137 |
|
138 | 138 | // Call utility classes (apply bob correction when Iris shaders are active) |
139 | 139 |
|
140 | | - Matrix4f correctedPosition = MixinPlugin.isIrisPresent && RenderUtils.isShaderPackInUse() ? new Matrix4f(position).mul(inverseBob) : position; |
| 140 | + Matrix4f correctedPosition = (MixinPlugin.isIrisPresent && IrisApi.getInstance().isShaderPackInUse()) ? new Matrix4f(position).mul(inverseBob) : position; |
141 | 141 | RenderUtils.updateScreenCenter(projection, correctedPosition); |
142 | 142 | NametagUtils.onRender(position); |
143 | 143 |
|
|
0 commit comments