ChatCapture

Open chat-capture windows for run_command target=client. The ChatComponent mixins append every chat line to all open windows; run opens one before sending a command and closes it after the capture window. Public because the mixins live in a different package.

References only Capture, ChatTrust, network.chat.Component and JDK types — never a net.minecraft.client.* class — so it links cleanly on a dedicated server (where it is never used).

Constructors

Link copied to clipboard
private constructor()

Types

Link copied to clipboard
class Window
A sink and the policy it was opened under.

Properties

Link copied to clipboard
One per open window, and every window gets EVERY line: a chat line carries nothing tying it back to the command that caused it, so concurrent run_commands necessarily see each other's output.

Functions

Link copied to clipboard
open fun append(c: Component)
Every entry but 26.
open fun append(c: Component, knownPlayer: Boolean)
knownPlayer is that entry's structural certainty; everything else asks ChatTrust, which is the expensive half — hence the empty check first.
Link copied to clipboard
Link copied to clipboard
open fun open(sink: Capture, allowUntrusted: Boolean): ChatCapture.Window