Skip to content

Commit 9790cd0

Browse files
committed
🐛 Fix exp level not affected by console hotbar
1 parent 075af45 commit 9790cd0

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed

fabric/build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ dependencies {
1515
modCompileOnly "mezz.jei:jei-${jei_minecraft_version}-fabric:${jei_version}"
1616
modCompileOnly "dev.emi:emi-fabric:${emi_version}"
1717
modCompileOnly "me.shedaniel:RoughlyEnoughItems-fabric:${rei_version}"
18+
//modRuntimeOnly "squeek.appleskin:appleskin-fabric:mc1.21.3-3.0.6"
1819
library include("com.mrcrayfish:controllable-sdl:${controllable_sdl_version}") {
1920
transitive(false)
2021
}

fabric/src/main/java/com/mrcrayfish/controllable/mixin/client/FabricGuiMixin.java

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,23 @@ private void consoleHotbarOffsetTail(GuiGraphics graphics, DeltaTracker tracker,
3333
graphics.pose().popPose();
3434
}
3535
}
36+
37+
@Inject(method = "renderExperienceLevel", at = @At(value = "HEAD"))
38+
private void consoleExpLevelHead(GuiGraphics graphics, DeltaTracker tracker, CallbackInfo ci)
39+
{
40+
if(Config.CLIENT.options.consoleHotbar.get())
41+
{
42+
graphics.pose().pushPose();
43+
graphics.pose().translate(0, -25, 0);
44+
}
45+
}
46+
47+
@Inject(method = "renderExperienceLevel", at = @At(value = "TAIL"))
48+
private void consoleExpLevelTail(GuiGraphics graphics, DeltaTracker tracker, CallbackInfo ci)
49+
{
50+
if(Config.CLIENT.options.consoleHotbar.get())
51+
{
52+
graphics.pose().popPose();
53+
}
54+
}
3655
}

0 commit comments

Comments
 (0)