DialogueLine

A line of dialogue.

Properties

character

var character: String
public string Character

The name of the character speaking (or "").

concurrent_lines

var concurrent_lines: Array[DialogueLine]
public Array<DialogueLine> ConcurrentLines

A list of lines that are to be spoken at the same time as this one.

id

var id: String
public string Id

The ID of the line.

next_id

var next_id: String
public string NextId

The ID of the next line of dialogue after this one.

responses

var responses: Array[DialogueResponse]
public Array<DialogueResponse> Responses

The list of responses to this line (if any).

static_id

var static_id: String
public string StaticId

The key used to translate the text (or the whole text again if no ID was specified on the line).

tags

var tags: PackedStringArray
public Array<string> Tags

A list of tags.

text

var text: String
public string Text

The text that the character is saying.

time

var time: string
public string Time

Methods

to_serialized

func to_serialized() -> String

Convert a line of dialogue to a string that can be used to restore it later.

new_from_serialized

static func new_from_serialized(serialized_string: String, extra_game_states: Array = []) -> DialogueLine

Restore a serialized line of dialogue. Pass in an array of game states if needed.

[!WARNING] Serializing only works with persisted resources, not resources that have been created with DialogueManager.create_resource_from_text().