Copyright © 2025-2026 Candy ArtsChat
The Chat displays Lines in Chat mode: Lines stacked one under the other, which the player can scroll back through to the very first one.
It's composed of four scenes, each with its own role:
| Scene | Role |
| Chat_Box | Lays out one or more Chat_Channels. |
| Chat_Channel | Runs the Lines (typewriter, voice, advance) and retains every one of them. This is the UI Element the Engine communicates with. |
| Chat_Line | Displays one Line: its text, with a portrait and a speaker label on each side. |
| Chat_Separator | Separates two Dialogues' Lines, when the first Dialogue's Lines are retained. |
- Script: Chat_Box.gd
- Templates: Scenes/Chat_Boxes
- Updates: the script is 'unsafe', and so is every template except Default.tscn (see Customizing UI Elements, on the UI page)
| Variable | Node |
| channels | Required. The Chat_Channels the Chat_Box lays out. |
- Script: Chat_Channel.gd
- Templates: Scenes/Chat_Channels
- Updates: the script is 'unsafe', and the Default.tscn template is 'safe' (see Customizing UI Elements, on the UI page)
- Engine path: chat_path in ui_elements_paths
| Variable | Node |
| lines_area | Required. The Control the Lines are drawn in. Its width is the Lines' width. |
| voice_node | Required. The voice player for this chat (see Voice Players). |
| scroll_bar | Optional. A VScrollBar to scroll the chat with. |
- Script: Chat_Line.gd
- Templates: Scenes/Chat_Lines
- Updates: the script is 'unsafe', and the Default.tscn template is 'safe' (see Customizing UI Elements, on the UI page)
| Variable | Node |
| text_node | Required. RichTextLabel: the spoken text. Turn on its fit_content, so the Line grows with its text. |
| portrait_left | Optional. The portrait on the left of the text: any node type listed in Media Files that shows images or videos. |
| portrait_right | Optional. The portrait on the right of the text. |
| speaker_left | Optional. RichTextLabel: the speaker's name, on the left. |
| speaker_right | Optional. RichTextLabel: the speaker's name, on the right. |
- The Chat_Channel sets the Line's width and reads its minimum height: use a Container that grows with its text as the root.
- Reserving a hidden portrait's space (chat_keep_portrait_space) relies on the portrait node's minimum size: set one.
- A Sprite2D portrait is scaled to the Chat_Line's portrait_w and portrait_h.
- Templates: Scenes/Chat_Separators
- Updates: the Default.tscn template is 'safe'