Skip to content

Commit

Permalink
Fix render tick not actually being called after gameRenderer.render
Browse files Browse the repository at this point in the history
  • Loading branch information
IThundxr committed Oct 20, 2024
1 parent 1197439 commit 0574534
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -128,12 +128,12 @@ private void addClientResources(GameConfig gameConfig, CallbackInfo ci) {
return original.call(gameMode, posBlock, directionFacing); // continue to continueDestroyBlock
}

@Inject(method = "runTick", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/renderer/GameRenderer;render(Lnet/minecraft/client/DeltaTracker;Z)V", shift = Shift.BEFORE))
@Inject(method = "runTick", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/renderer/GameRenderer;render(Lnet/minecraft/client/DeltaTracker;Z)V"))
private void renderTickStart(CallbackInfo ci) {
RenderFrameEvent.PRE.invoker().onRenderFrame(this.timer);
}

@Inject(method = "runTick", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/renderer/GameRenderer;render(Lnet/minecraft/client/DeltaTracker;Z)V"))
@Inject(method = "runTick", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/renderer/GameRenderer;render(Lnet/minecraft/client/DeltaTracker;Z)V", shift = Shift.AFTER))
private void renderTickEnd(CallbackInfo ci) {
RenderFrameEvent.POST.invoker().onRenderFrame(this.timer);
}
Expand Down

0 comments on commit 0574534

Please sign in to comment.