-
Notifications
You must be signed in to change notification settings - Fork 176
Open
Description
In the current 1.21.1 version of Malilib the injection of onRenderGameOverlayPost is done like this:
@Mixin(InGameHud.class)
public abstract class MixinInGameHud
{
@Shadow @Final private MinecraftClient client;
@Inject(method = "render", at = @At("RETURN"))
private void onGameOverlayPost(DrawContext context, RenderTickCounter tickCounter, CallbackInfo ci)
{
((RenderEventHandler) RenderEventHandler.getInstance()).onRenderGameOverlayPost(context, this.client, tickCounter.getTickDelta(false));
}
}but the render function there already has rendered all layers and disabled depth tests again:
public void render(DrawContext context, RenderTickCounter tickCounter) {
RenderSystem.enableDepthTest();
this.layeredDrawer.render(context, tickCounter);
RenderSystem.disableDepthTest();
}in the mod AdvancedChatHUD that results in chat boxes being behind the Hud
1.20.1 with MaliLib and AdvancedChatHUD

1.21.1 with MaliLib and AdvancedChatHUD

to fix that i've created a Mixin in AdvancedChatHUD that changes the onRenderGameOverlayPost to inject into layeredDrawer from Mojang to guarantee its rendered as the last layer
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels