summaryrefslogtreecommitdiff
path: root/src/main/java/moe/nea/ultranotifier/mixin/ChatHudMessageAdded.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/moe/nea/ultranotifier/mixin/ChatHudMessageAdded.java')
-rw-r--r--src/main/java/moe/nea/ultranotifier/mixin/ChatHudMessageAdded.java22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/main/java/moe/nea/ultranotifier/mixin/ChatHudMessageAdded.java b/src/main/java/moe/nea/ultranotifier/mixin/ChatHudMessageAdded.java
index 2b65282..12eedba 100644
--- a/src/main/java/moe/nea/ultranotifier/mixin/ChatHudMessageAdded.java
+++ b/src/main/java/moe/nea/ultranotifier/mixin/ChatHudMessageAdded.java
@@ -3,7 +3,7 @@ package moe.nea.ultranotifier.mixin;
import moe.nea.ultranotifier.event.ChatGuiLineEvent;
import moe.nea.ultranotifier.event.UltraNotifierEvents;
import net.minecraft.client.gui.hud.ChatHud;
-//#if MC > 11404
+//#if MC >= 1.20
import net.minecraft.client.gui.hud.MessageIndicator;
import net.minecraft.network.message.MessageSignatureData;
//#endif
@@ -18,22 +18,22 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
)
public class ChatHudMessageAdded {
@Inject(
-//#if MC <= 11404
-//#if FORGE
-//$$ method = "printChatMessageWithOptionalDeletion",
-//#else
-//$$ method = "addMessage(Lnet/minecraft/text/Text;I)V",
-//#endif
-//#else
+//#if MC >= 1.20
method = "addMessage(Lnet/minecraft/text/Text;Lnet/minecraft/network/message/MessageSignatureData;Lnet/minecraft/client/gui/hud/MessageIndicator;)V",
+//#elseif MC >= 1.16
+//$$ method = "addMessage(Lnet/minecraft/text/Text;IIZ)V",
+//#else
+//$$ method = "printChatMessageWithOptionalDeletion",
//#endif
at = @At("HEAD"), cancellable = true)
private void onAddMessage(
Text message,
-//#if MC <= 11404
-//$$ int chatLineId,
-//#else
+//#if MC >= 1.20
MessageSignatureData signatureData, MessageIndicator indicator,
+//#elseif MC >= 1.16
+//$$ int chatLineId, int timestamp, boolean bl,
+//#else
+//$$ int chatLineId,
//#endif
CallbackInfo ci
) {