aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/moe/nea/firmament/mixins/HudRenderEvents.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/moe/nea/firmament/mixins/HudRenderEvents.java')
-rw-r--r--src/main/java/moe/nea/firmament/mixins/HudRenderEvents.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/java/moe/nea/firmament/mixins/HudRenderEvents.java b/src/main/java/moe/nea/firmament/mixins/HudRenderEvents.java
index ff4e995..111ab33 100644
--- a/src/main/java/moe/nea/firmament/mixins/HudRenderEvents.java
+++ b/src/main/java/moe/nea/firmament/mixins/HudRenderEvents.java
@@ -1,5 +1,6 @@
/*
* SPDX-FileCopyrightText: 2023 Linnea Gräf <nea@nea.moe>
+ * SPDX-FileCopyrightText: 2024 Linnea Gräf <nea@nea.moe>
*
* SPDX-License-Identifier: GPL-3.0-or-later
*/
@@ -19,13 +20,13 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
@Mixin(InGameHud.class)
public class HudRenderEvents {
- @Inject(method = "render", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/network/ClientPlayerEntity;getSleepTimer()I"))
+ @Inject(method = "renderSleepOverlay", at = @At(value = "TAIL"))
public void renderCallBack(DrawContext context, float tickDelta, CallbackInfo ci) {
HudRenderEvent.Companion.publish(new HudRenderEvent(context, tickDelta));
}
@Inject(method = "renderHotbarItem", at = @At("HEAD"))
- public void onRenderHotbarItem(DrawContext context, int x, int y, float tickDelta, PlayerEntity player, ItemStack stack, int seed,CallbackInfo ci) {
+ public void onRenderHotbarItem(DrawContext context, int x, int y, float tickDelta, PlayerEntity player, ItemStack stack, int seed, CallbackInfo ci) {
if (stack != null && !stack.isEmpty())
HotbarItemRenderEvent.Companion.publish(new HotbarItemRenderEvent(stack, context, x, y, tickDelta));
}