aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
authorCalMWolfs <94038482+CalMWolfs@users.noreply.github.com>2024-06-01 19:29:23 +1000
committerGitHub <noreply@github.com>2024-06-01 11:29:23 +0200
commitaf5dbdb3ad0f64f22bd0692d12483e7d040d7ac7 (patch)
tree09c2a475f859bb991e52e2a7734f5d1973a442b0 /src/main/java
parent7edef27128078b6a5e5defcc0c84f919a5af6aad (diff)
downloadskyhanni-af5dbdb3ad0f64f22bd0692d12483e7d040d7ac7.tar.gz
skyhanni-af5dbdb3ad0f64f22bd0692d12483e7d040d7ac7.tar.bz2
skyhanni-af5dbdb3ad0f64f22bd0692d12483e7d040d7ac7.zip
Fix: Movable hotbar messing with some other mods (#1965)
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/gui/MovableHotBar.kt5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/gui/MovableHotBar.kt b/src/main/java/at/hannibal2/skyhanni/features/gui/MovableHotBar.kt
index 37a86eb22..636bb64ef 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/gui/MovableHotBar.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/gui/MovableHotBar.kt
@@ -7,6 +7,7 @@ import at.hannibal2.skyhanni.utils.RenderUtils.transform
import net.minecraft.client.Minecraft
import net.minecraft.client.renderer.GlStateManager
import net.minecraftforge.client.event.RenderGameOverlayEvent
+import net.minecraftforge.fml.common.eventhandler.EventPriority
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
class MovableHotBar {
@@ -15,7 +16,7 @@ class MovableHotBar {
private var post = false
- @SubscribeEvent
+ @SubscribeEvent(priority = EventPriority.LOWEST)
fun onRenderHotbar(event: RenderGameOverlayEvent.Pre) {
if (event.type != RenderGameOverlayEvent.ElementType.HOTBAR || !isEnabled()) return
post = true
@@ -28,7 +29,7 @@ class MovableHotBar {
GuiEditManager.add(config.hotbar, "Hotbar", 182 - 1, 22 - 1) // -1 since the editor for some reason add +1
}
- @SubscribeEvent
+ @SubscribeEvent(priority = EventPriority.HIGHEST)
fun onRenderHotbar(event: RenderGameOverlayEvent.Post) {
if (event.type != RenderGameOverlayEvent.ElementType.HOTBAR || !post) return
GlStateManager.popMatrix()