Class ChatHud

java.lang.Object
net.minecraft.client.gui.DrawableHelper
net.minecraft.client.gui.hud.ChatHud

@Environment(CLIENT) public class ChatHud extends DrawableHelper
Responsible for rendering various game messages such as chat messages or join/leave messages.
See Also:
Mappings:
Namespace Name
official ela
intermediary net/minecraft/class_338
named net/minecraft/client/gui/hud/ChatHud
  • Field Details

    • LOGGER

      private static final Logger LOGGER
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a:Lorg/slf4j/Logger;
      intermediary field_2065 Lnet/minecraft/class_338;field_2065:Lorg/slf4j/Logger;
      named LOGGER Lnet/minecraft/client/gui/hud/ChatHud;LOGGER:Lorg/slf4j/Logger;
    • MAX_MESSAGES

      private static final int MAX_MESSAGES
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official b Lela;b:I
      intermediary field_32180 Lnet/minecraft/class_338;field_32180:I
      named MAX_MESSAGES Lnet/minecraft/client/gui/hud/ChatHud;MAX_MESSAGES:I
    • MISSING_MESSAGE_INDEX

      private static final int MISSING_MESSAGE_INDEX
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official c Lela;c:I
      intermediary field_39771 Lnet/minecraft/class_338;field_39771:I
      named MISSING_MESSAGE_INDEX Lnet/minecraft/client/gui/hud/ChatHud;MISSING_MESSAGE_INDEX:I
    • field_39772

      private static final int field_39772
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official d Lela;d:I
      intermediary field_39772 Lnet/minecraft/class_338;field_39772:I
      named field_39772 Lnet/minecraft/client/gui/hud/ChatHud;field_39772:I
    • field_39773

      private static final int field_39773
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official e Lela;e:I
      intermediary field_39773 Lnet/minecraft/class_338;field_39773:I
      named field_39773 Lnet/minecraft/client/gui/hud/ChatHud;field_39773:I
    • field_40389

      private static final int field_40389
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official f Lela;f:I
      intermediary field_40389 Lnet/minecraft/class_338;field_40389:I
      named field_40389 Lnet/minecraft/client/gui/hud/ChatHud;field_40389:I
    • field_40390

      private static final int field_40390
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official j Lela;j:I
      intermediary field_40390 Lnet/minecraft/class_338;field_40390:I
      named field_40390 Lnet/minecraft/client/gui/hud/ChatHud;field_40390:I
    • DELETED_MARKER_TEXT

      private static final Text DELETED_MARKER_TEXT
      Mappings:
      Namespace Name Mixin selector
      official k Lela;k:Lss;
      intermediary field_40391 Lnet/minecraft/class_338;field_40391:Lnet/minecraft/class_2561;
      named DELETED_MARKER_TEXT Lnet/minecraft/client/gui/hud/ChatHud;DELETED_MARKER_TEXT:Lnet/minecraft/text/Text;
    • client

      private final MinecraftClient client
      Mappings:
      Namespace Name Mixin selector
      official l Lela;l:Lejf;
      intermediary field_2062 Lnet/minecraft/class_338;field_2062:Lnet/minecraft/class_310;
      named client Lnet/minecraft/client/gui/hud/ChatHud;client:Lnet/minecraft/client/MinecraftClient;
    • messageHistory

      private final List<String> messageHistory
      Mappings:
      Namespace Name Mixin selector
      official m Lela;m:Ljava/util/List;
      intermediary field_2063 Lnet/minecraft/class_338;field_2063:Ljava/util/List;
      named messageHistory Lnet/minecraft/client/gui/hud/ChatHud;messageHistory:Ljava/util/List;
    • messages

      private final List<ChatHudLine> messages
      Mappings:
      Namespace Name Mixin selector
      official n Lela;n:Ljava/util/List;
      intermediary field_2061 Lnet/minecraft/class_338;field_2061:Ljava/util/List;
      named messages Lnet/minecraft/client/gui/hud/ChatHud;messages:Ljava/util/List;
    • visibleMessages

      private final List<ChatHudLine.Visible> visibleMessages
      Mappings:
      Namespace Name Mixin selector
      official o Lela;o:Ljava/util/List;
      intermediary field_2064 Lnet/minecraft/class_338;field_2064:Ljava/util/List;
      named visibleMessages Lnet/minecraft/client/gui/hud/ChatHud;visibleMessages:Ljava/util/List;
    • scrolledLines

      private int scrolledLines
      Mappings:
      Namespace Name Mixin selector
      official p Lela;p:I
      intermediary field_2066 Lnet/minecraft/class_338;field_2066:I
      named scrolledLines Lnet/minecraft/client/gui/hud/ChatHud;scrolledLines:I
    • hasUnreadNewMessages

      private boolean hasUnreadNewMessages
      Mappings:
      Namespace Name Mixin selector
      official q Lela;q:Z
      intermediary field_2067 Lnet/minecraft/class_338;field_2067:Z
      named hasUnreadNewMessages Lnet/minecraft/client/gui/hud/ChatHud;hasUnreadNewMessages:Z
    • removalQueue

      private final List<ChatHud.RemovalQueuedMessage> removalQueue
      Mappings:
      Namespace Name Mixin selector
      official r Lela;r:Ljava/util/List;
      intermediary field_40392 Lnet/minecraft/class_338;field_40392:Ljava/util/List;
      named removalQueue Lnet/minecraft/client/gui/hud/ChatHud;removalQueue:Ljava/util/List;
  • Constructor Details

    • ChatHud

      public ChatHud(MinecraftClient client)
      Mappings:
      Namespace Name Mixin selector
      official <init> Lela;<init>(Lejf;)V
      intermediary <init> Lnet/minecraft/class_338;<init>(Lnet/minecraft/class_310;)V
      named <init> Lnet/minecraft/client/gui/hud/ChatHud;<init>(Lnet/minecraft/client/MinecraftClient;)V
  • Method Details

    • tickRemovalQueueIfExists

      public void tickRemovalQueueIfExists()
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a()V
      intermediary method_45584 Lnet/minecraft/class_338;method_45584()V
      named tickRemovalQueueIfExists Lnet/minecraft/client/gui/hud/ChatHud;tickRemovalQueueIfExists()V
    • render

      public void render(MatrixStack matrices, int currentTick, int mouseX, int mouseY)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Leed;III)V
      intermediary method_1805 Lnet/minecraft/class_338;method_1805(Lnet/minecraft/class_4587;III)V
      named render Lnet/minecraft/client/gui/hud/ChatHud;render(Lnet/minecraft/client/util/math/MatrixStack;III)V
    • drawIndicatorIcon

      private void drawIndicatorIcon(MatrixStack matrices, int x, int y, MessageIndicator.Icon icon)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Leed;IILejb$a;)V
      intermediary method_44719 Lnet/minecraft/class_338;method_44719(Lnet/minecraft/class_4587;IILnet/minecraft/class_7591$class_7592;)V
      named drawIndicatorIcon Lnet/minecraft/client/gui/hud/ChatHud;drawIndicatorIcon(Lnet/minecraft/client/util/math/MatrixStack;IILnet/minecraft/client/gui/hud/MessageIndicator$Icon;)V
    • getIndicatorX

      private int getIndicatorX(ChatHudLine.Visible line)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Leja$a;)I
      intermediary method_44720 Lnet/minecraft/class_338;method_44720(Lnet/minecraft/class_303$class_7590;)I
      named getIndicatorX Lnet/minecraft/client/gui/hud/ChatHud;getIndicatorX(Lnet/minecraft/client/gui/hud/ChatHudLine$Visible;)I
    • isChatHidden

      private boolean isChatHidden()
      Mappings:
      Namespace Name Mixin selector
      official j Lela;j()Z
      intermediary method_23677 Lnet/minecraft/class_338;method_23677()Z
      named isChatHidden Lnet/minecraft/client/gui/hud/ChatHud;isChatHidden()Z
    • getMessageOpacityMultiplier

      private static double getMessageOpacityMultiplier(int age)
      Mappings:
      Namespace Name Mixin selector
      official b Lela;b(I)D
      intermediary method_19348 Lnet/minecraft/class_338;method_19348(I)D
      named getMessageOpacityMultiplier Lnet/minecraft/client/gui/hud/ChatHud;getMessageOpacityMultiplier(I)D
    • clear

      public void clear(boolean clearHistory)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Z)V
      intermediary method_1808 Lnet/minecraft/class_338;method_1808(Z)V
      named clear Lnet/minecraft/client/gui/hud/ChatHud;clear(Z)V
    • addMessage

      public void addMessage(Text message)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Lss;)V
      intermediary method_1812 Lnet/minecraft/class_338;method_1812(Lnet/minecraft/class_2561;)V
      named addMessage Lnet/minecraft/client/gui/hud/ChatHud;addMessage(Lnet/minecraft/text/Text;)V
    • addMessage

      public void addMessage(Text message, @Nullable @Nullable MessageSignatureData signature, @Nullable @Nullable MessageIndicator indicator)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Lss;Ltd;Lejb;)V
      intermediary method_44811 Lnet/minecraft/class_338;method_44811(Lnet/minecraft/class_2561;Lnet/minecraft/class_7469;Lnet/minecraft/class_7591;)V
      named addMessage Lnet/minecraft/client/gui/hud/ChatHud;addMessage(Lnet/minecraft/text/Text;Lnet/minecraft/network/message/MessageSignatureData;Lnet/minecraft/client/gui/hud/MessageIndicator;)V
    • logChatMessage

      private void logChatMessage(Text message, @Nullable @Nullable MessageIndicator indicator)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Lss;Lejb;)V
      intermediary method_45027 Lnet/minecraft/class_338;method_45027(Lnet/minecraft/class_2561;Lnet/minecraft/class_7591;)V
      named logChatMessage Lnet/minecraft/client/gui/hud/ChatHud;logChatMessage(Lnet/minecraft/text/Text;Lnet/minecraft/client/gui/hud/MessageIndicator;)V
    • addMessage

      private void addMessage(Text message, @Nullable @Nullable MessageSignatureData signature, int ticks, @Nullable @Nullable MessageIndicator indicator, boolean refresh)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Lss;Ltd;ILejb;Z)V
      intermediary method_1815 Lnet/minecraft/class_338;method_1815(Lnet/minecraft/class_2561;Lnet/minecraft/class_7469;ILnet/minecraft/class_7591;Z)V
      named addMessage Lnet/minecraft/client/gui/hud/ChatHud;addMessage(Lnet/minecraft/text/Text;Lnet/minecraft/network/message/MessageSignatureData;ILnet/minecraft/client/gui/hud/MessageIndicator;Z)V
    • tickRemovalQueue

      private void tickRemovalQueue()
      Mappings:
      Namespace Name Mixin selector
      official k Lela;k()V
      intermediary method_45589 Lnet/minecraft/class_338;method_45589()V
      named tickRemovalQueue Lnet/minecraft/client/gui/hud/ChatHud;tickRemovalQueue()V
    • removeMessage

      public void removeMessage(MessageSignatureData signature)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Ltd;)V
      intermediary method_44812 Lnet/minecraft/class_338;method_44812(Lnet/minecraft/class_7469;)V
      named removeMessage Lnet/minecraft/client/gui/hud/ChatHud;removeMessage(Lnet/minecraft/network/message/MessageSignatureData;)V
    • queueForRemoval

      Mappings:
      Namespace Name Mixin selector
      official b Lela;b(Ltd;)Lela$a;
      intermediary method_45587 Lnet/minecraft/class_338;method_45587(Lnet/minecraft/class_7469;)Lnet/minecraft/class_338$class_7731;
      named queueForRemoval Lnet/minecraft/client/gui/hud/ChatHud;queueForRemoval(Lnet/minecraft/network/message/MessageSignatureData;)Lnet/minecraft/client/gui/hud/ChatHud$RemovalQueuedMessage;
    • createRemovalMarker

      private ChatHudLine createRemovalMarker(ChatHudLine original)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Leja;)Leja;
      intermediary method_45586 Lnet/minecraft/class_338;method_45586(Lnet/minecraft/class_303;)Lnet/minecraft/class_303;
      named createRemovalMarker Lnet/minecraft/client/gui/hud/ChatHud;createRemovalMarker(Lnet/minecraft/client/gui/hud/ChatHudLine;)Lnet/minecraft/client/gui/hud/ChatHudLine;
    • reset

      public void reset()
      Mappings:
      Namespace Name Mixin selector
      official b Lela;b()V
      intermediary method_1817 Lnet/minecraft/class_338;method_1817()V
      named reset Lnet/minecraft/client/gui/hud/ChatHud;reset()V
    • refresh

      private void refresh()
      Mappings:
      Namespace Name Mixin selector
      official n Lela;n()V
      intermediary method_44813 Lnet/minecraft/class_338;method_44813()V
      named refresh Lnet/minecraft/client/gui/hud/ChatHud;refresh()V
    • getMessageHistory

      public List<String> getMessageHistory()
      Mappings:
      Namespace Name Mixin selector
      official c Lela;c()Ljava/util/List;
      intermediary method_1809 Lnet/minecraft/class_338;method_1809()Ljava/util/List;
      named getMessageHistory Lnet/minecraft/client/gui/hud/ChatHud;getMessageHistory()Ljava/util/List;
    • addToMessageHistory

      public void addToMessageHistory(String message)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(Ljava/lang/String;)V
      intermediary method_1803 Lnet/minecraft/class_338;method_1803(Ljava/lang/String;)V
      named addToMessageHistory Lnet/minecraft/client/gui/hud/ChatHud;addToMessageHistory(Ljava/lang/String;)V
    • resetScroll

      public void resetScroll()
      Mappings:
      Namespace Name Mixin selector
      official d Lela;d()V
      intermediary method_1820 Lnet/minecraft/class_338;method_1820()V
      named resetScroll Lnet/minecraft/client/gui/hud/ChatHud;resetScroll()V
    • scroll

      public void scroll(int scroll)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(I)V
      intermediary method_1802 Lnet/minecraft/class_338;method_1802(I)V
      named scroll Lnet/minecraft/client/gui/hud/ChatHud;scroll(I)V
    • mouseClicked

      public boolean mouseClicked(double mouseX, double mouseY)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(DD)Z
      intermediary method_27146 Lnet/minecraft/class_338;method_27146(DD)Z
      named mouseClicked Lnet/minecraft/client/gui/hud/ChatHud;mouseClicked(DD)Z
    • getTextStyleAt

      @Nullable public @Nullable Style getTextStyleAt(double x, double y)
      Mappings:
      Namespace Name Mixin selector
      official b Lela;b(DD)Lto;
      intermediary method_1816 Lnet/minecraft/class_338;method_1816(DD)Lnet/minecraft/class_2583;
      named getTextStyleAt Lnet/minecraft/client/gui/hud/ChatHud;getTextStyleAt(DD)Lnet/minecraft/text/Style;
    • getIndicatorAt

      @Nullable public @Nullable MessageIndicator getIndicatorAt(double mouseX, double mouseY)
      Mappings:
      Namespace Name Mixin selector
      official c Lela;c(DD)Lejb;
      intermediary method_44723 Lnet/minecraft/class_338;method_44723(DD)Lnet/minecraft/class_7591;
      named getIndicatorAt Lnet/minecraft/client/gui/hud/ChatHud;getIndicatorAt(DD)Lnet/minecraft/client/gui/hud/MessageIndicator;
    • isXInsideIndicatorIcon

      private boolean isXInsideIndicatorIcon(double x, ChatHudLine.Visible line, MessageIndicator indicator)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(DLeja$a;Lejb;)Z
      intermediary method_44718 Lnet/minecraft/class_338;method_44718(DLnet/minecraft/class_303$class_7590;Lnet/minecraft/class_7591;)Z
      named isXInsideIndicatorIcon Lnet/minecraft/client/gui/hud/ChatHud;isXInsideIndicatorIcon(DLnet/minecraft/client/gui/hud/ChatHudLine$Visible;Lnet/minecraft/client/gui/hud/MessageIndicator;)Z
    • toChatLineX

      private double toChatLineX(double x)
      Mappings:
      Namespace Name Mixin selector
      official c Lela;c(D)D
      intermediary method_44722 Lnet/minecraft/class_338;method_44722(D)D
      named toChatLineX Lnet/minecraft/client/gui/hud/ChatHud;toChatLineX(D)D
    • toChatLineY

      private double toChatLineY(double y)
      Mappings:
      Namespace Name Mixin selector
      official d Lela;d(D)D
      intermediary method_44724 Lnet/minecraft/class_338;method_44724(D)D
      named toChatLineY Lnet/minecraft/client/gui/hud/ChatHud;toChatLineY(D)D
    • getMessageIndex

      private int getMessageIndex(double chatLineX, double chatLineY)
      Mappings:
      Namespace Name Mixin selector
      official d Lela;d(DD)I
      intermediary method_45588 Lnet/minecraft/class_338;method_45588(DD)I
      named getMessageIndex Lnet/minecraft/client/gui/hud/ChatHud;getMessageIndex(DD)I
    • getMessageLineIndex

      private int getMessageLineIndex(double chatLineX, double chatLineY)
      Mappings:
      Namespace Name Mixin selector
      official e Lela;e(DD)I
      intermediary method_44725 Lnet/minecraft/class_338;method_44725(DD)I
      named getMessageLineIndex Lnet/minecraft/client/gui/hud/ChatHud;getMessageLineIndex(DD)I
    • isChatFocused

      private boolean isChatFocused()
      Mappings:
      Namespace Name Mixin selector
      official o Lela;o()Z
      intermediary method_1819 Lnet/minecraft/class_338;method_1819()Z
      named isChatFocused Lnet/minecraft/client/gui/hud/ChatHud;isChatFocused()Z
    • getWidth

      public int getWidth()
      Mappings:
      Namespace Name Mixin selector
      official e Lela;e()I
      intermediary method_1811 Lnet/minecraft/class_338;method_1811()I
      named getWidth Lnet/minecraft/client/gui/hud/ChatHud;getWidth()I
    • getHeight

      public int getHeight()
      Mappings:
      Namespace Name Mixin selector
      official f Lela;f()I
      intermediary method_1810 Lnet/minecraft/class_338;method_1810()I
      named getHeight Lnet/minecraft/client/gui/hud/ChatHud;getHeight()I
    • getChatScale

      public double getChatScale()
      Mappings:
      Namespace Name Mixin selector
      official g Lela;g()D
      intermediary method_1814 Lnet/minecraft/class_338;method_1814()D
      named getChatScale Lnet/minecraft/client/gui/hud/ChatHud;getChatScale()D
    • getWidth

      public static int getWidth(double widthOption)
      Mappings:
      Namespace Name Mixin selector
      official a Lela;a(D)I
      intermediary method_1806 Lnet/minecraft/class_338;method_1806(D)I
      named getWidth Lnet/minecraft/client/gui/hud/ChatHud;getWidth(D)I
    • getHeight

      public static int getHeight(double heightOption)
      Mappings:
      Namespace Name Mixin selector
      official b Lela;b(D)I
      intermediary method_1818 Lnet/minecraft/class_338;method_1818(D)I
      named getHeight Lnet/minecraft/client/gui/hud/ChatHud;getHeight(D)I
    • getDefaultUnfocusedHeight

      public static double getDefaultUnfocusedHeight()
      Mappings:
      Namespace Name Mixin selector
      official h Lela;h()D
      intermediary method_41831 Lnet/minecraft/class_338;method_41831()D
      named getDefaultUnfocusedHeight Lnet/minecraft/client/gui/hud/ChatHud;getDefaultUnfocusedHeight()D
    • getVisibleLineCount

      public int getVisibleLineCount()
      Mappings:
      Namespace Name Mixin selector
      official i Lela;i()I
      intermediary method_1813 Lnet/minecraft/class_338;method_1813()I
      named getVisibleLineCount Lnet/minecraft/client/gui/hud/ChatHud;getVisibleLineCount()I
    • getLineHeight

      private int getLineHeight()
      Mappings:
      Namespace Name Mixin selector
      official p Lela;p()I
      intermediary method_44752 Lnet/minecraft/class_338;method_44752()I
      named getLineHeight Lnet/minecraft/client/gui/hud/ChatHud;getLineHeight()I