aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/moe/nea/firmament/mixins/CustomDurabilityBarPatch.java
diff options
context:
space:
mode:
authorLinnea Gräf <nea@nea.moe>2024-11-03 01:24:24 +0100
committerLinnea Gräf <nea@nea.moe>2024-11-03 01:24:24 +0100
commite2677d6ee5c3f74d5f547ca48bf6641f047a2a1e (patch)
treefecc0322e48a399df7697da11adfb022d5641a6c /src/main/java/moe/nea/firmament/mixins/CustomDurabilityBarPatch.java
parent646843ba3b960ac48f9866b3640438d3cc1dafc4 (diff)
downloadFirmament-e2677d6ee5c3f74d5f547ca48bf6641f047a2a1e.tar.gz
Firmament-e2677d6ee5c3f74d5f547ca48bf6641f047a2a1e.tar.bz2
Firmament-e2677d6ee5c3f74d5f547ca48bf6641f047a2a1e.zip
1.21.3 WIP
Diffstat (limited to 'src/main/java/moe/nea/firmament/mixins/CustomDurabilityBarPatch.java')
-rw-r--r--src/main/java/moe/nea/firmament/mixins/CustomDurabilityBarPatch.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/moe/nea/firmament/mixins/CustomDurabilityBarPatch.java b/src/main/java/moe/nea/firmament/mixins/CustomDurabilityBarPatch.java
index 0f4d324..fde3580 100644
--- a/src/main/java/moe/nea/firmament/mixins/CustomDurabilityBarPatch.java
+++ b/src/main/java/moe/nea/firmament/mixins/CustomDurabilityBarPatch.java
@@ -14,7 +14,7 @@ import org.spongepowered.asm.mixin.injection.At;
@Mixin(DrawContext.class)
public class CustomDurabilityBarPatch {
@WrapOperation(
- method = "drawItemInSlot(Lnet/minecraft/client/font/TextRenderer;Lnet/minecraft/item/ItemStack;IILjava/lang/String;)V",
+ method = "drawItemBar",
at = @At(value = "INVOKE", target = "Lnet/minecraft/item/ItemStack;isItemBarVisible()Z")
)
private boolean onIsItemBarVisible(
@@ -29,7 +29,7 @@ public class CustomDurabilityBarPatch {
return barOverride.get() != null;
}
- @WrapOperation(method = "drawItemInSlot(Lnet/minecraft/client/font/TextRenderer;Lnet/minecraft/item/ItemStack;IILjava/lang/String;)V",
+ @WrapOperation(method = "drawItemBar",
at = @At(value = "INVOKE", target = "Lnet/minecraft/item/ItemStack;getItemBarStep()I"))
private int overrideItemStep(
ItemStack instance, Operation<Integer> original,
@@ -40,7 +40,7 @@ public class CustomDurabilityBarPatch {
return original.call(instance);
}
- @WrapOperation(method = "drawItemInSlot(Lnet/minecraft/client/font/TextRenderer;Lnet/minecraft/item/ItemStack;IILjava/lang/String;)V",
+ @WrapOperation(method = "drawItemBar",
at = @At(value = "INVOKE", target = "Lnet/minecraft/item/ItemStack;getItemBarColor()I"))
private int overrideItemColor(
ItemStack instance, Operation<Integer> original,