Class ChatListener
java.lang.Object
net.minecraft.client.multiplayer.chat.ChatListener
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final Componentprivate final Deque<ChatListener.Message> private longprivate final Minecraftprivate long -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidprivate ChatTrustLevelevaluateTrustLevel(PlayerChatMessage pChatMessage, Component pDecoratedServerContent, Instant pTimestamp) voidprivate UUIDguessChatUUID(Component pMessage) voidhandleChatMessageError(UUID pSender, MessageSignature pSignature, ChatType.Bound pBoundChatType) voidhandleDisguisedChatMessage(Component pMessage, ChatType.Bound pBoundChatType) private voidhandleMessage(MessageSignature pSignature, BooleanSupplier pHandler) voidhandlePlayerChatMessage(PlayerChatMessage pChatMessage, com.mojang.authlib.GameProfile pGameProfile, ChatType.Bound pBoundChatType) voidhandleSystemMessage(Component pMessage, boolean pIsOverlay) private booleanisSenderLocalPlayer(UUID pSender) private voidlogPlayerMessage(PlayerChatMessage pMessage, com.mojang.authlib.GameProfile pProfile, ChatTrustLevel pTrustLevel) private voidlogSystemMessage(Component pMessage, Instant pTimestamp) private voidnarrateChatMessage(ChatType.Bound pBoundChatType, Component pMessage) longbooleanremoveFromDelayedMessageQueue(MessageSignature pSignature) voidsetMessageDelay(double pDelaySeconds) private booleanshowMessageToPlayer(ChatType.Bound pBoundChatType, PlayerChatMessage pChatMessage, Component pDecoratedServerContent, com.mojang.authlib.GameProfile pGameProfile, boolean pOnlyShowSecureChat, Instant pTimestamp) voidtick()private boolean
-
Field Details
-
CHAT_VALIDATION_ERROR
-
minecraft
-
delayedMessageQueue
-
messageDelay
private long messageDelay -
previousMessageTime
private long previousMessageTime
-
-
Constructor Details
-
ChatListener
-
-
Method Details
-
tick
public void tick() -
setMessageDelay
public void setMessageDelay(double pDelaySeconds) -
acceptNextDelayedMessage
public void acceptNextDelayedMessage() -
queueSize
public long queueSize() -
flushQueue
public void flushQueue() -
removeFromDelayedMessageQueue
-
willDelayMessages
private boolean willDelayMessages() -
handleMessage
-
handlePlayerChatMessage
public void handlePlayerChatMessage(PlayerChatMessage pChatMessage, com.mojang.authlib.GameProfile pGameProfile, ChatType.Bound pBoundChatType) -
handleChatMessageError
public void handleChatMessageError(UUID pSender, @Nullable MessageSignature pSignature, ChatType.Bound pBoundChatType) -
handleDisguisedChatMessage
-
showMessageToPlayer
private boolean showMessageToPlayer(ChatType.Bound pBoundChatType, PlayerChatMessage pChatMessage, Component pDecoratedServerContent, com.mojang.authlib.GameProfile pGameProfile, boolean pOnlyShowSecureChat, Instant pTimestamp) -
narrateChatMessage
-
evaluateTrustLevel
private ChatTrustLevel evaluateTrustLevel(PlayerChatMessage pChatMessage, Component pDecoratedServerContent, Instant pTimestamp) -
logPlayerMessage
private void logPlayerMessage(PlayerChatMessage pMessage, com.mojang.authlib.GameProfile pProfile, ChatTrustLevel pTrustLevel) -
logSystemMessage
-
handleSystemMessage
-
guessChatUUID
-
isSenderLocalPlayer
-