PixelCrushers.DialogueSystem.DialogueEntry Class Reference

A dialogue entry is a single line of dialogue in a Conversation, with a list of links to possible responses (see Link). More...

Collaboration diagram for PixelCrushers.DialogueSystem.DialogueEntry:

Public Member Functions

bool HasResponseMenuSequence ()
 Indicates whether this entry has a response menu sequence. More...
 
 DialogueEntry ()
 Initializes a new DialogueEntry. More...
 
 DialogueEntry (ChatMapper.DialogEntry chatMapperDialogEntry)
 Initializes a new DialogueEntry copied from a Chat Mapper DialogEntry. More...
 
void UseCanvasRectField ()
 If the dialogue entry has a canvasRect field, extract it and use it to set the canvas rect position. More...
 
 DialogueEntry (DialogueEntry sourceEntry)
 Copy constructor. More...
 

Public Attributes

int id = 0
 The dialogue entry ID. More...
 
List< Fieldfields = null
 The dialogue entry's field list. More...
 
int conversationID = 0
 The ID of the conversation that this dialogue entry belongs to. More...
 
bool isRoot = false
 true if this is the root (first) entry in a conversation; otherwise false. More...
 
bool isGroup = false
 true if this entry is an empty line used to group a subtree of dialogue entries. More...
 
string nodeColor = null
 Currently unused by the dialogue system, this is the nodeColor value defined in Chat Mapper. More...
 
bool delaySimStatus = false
 Currently unused by the dialogue system, this is the delay value to use in Chat Mapper's conversation simulator. More...
 
string falseConditionAction = null
 Specifies how to proceed when encountering a link whose entry's condition is false. More...
 
ConditionPriority conditionPriority = ConditionPriority.Normal
 The priority of the link. More...
 
List< LinkoutgoingLinks = new List<Link>()
 The list of outgoing links from this dialogue entry. More...
 
string conditionsString = null
 A Lua conditional expression. More...
 
string userScript = null
 Lua code to run when this dialogue entry is spoken. More...
 
UnityEngine.Events.UnityEvent onExecute = new UnityEngine.Events.UnityEvent()
 
Rect canvasRect = new Rect(0, 0, CanvasRectWidth, CanvasRectHeight)
 The position of this entry on the Dialogue Editor's node canvas. More...
 

Static Public Attributes

const float CanvasRectWidth = 160f
 
const float CanvasRectHeight = 30f
 

Properties

int ActorID [get, set]
 Gets or sets the ID of the line's actor (speaker). More...
 
int ConversantID [get, set]
 Gets or sets the ID of the line's conversant (listener). More...
 
string Title [get, set]
 Gets or sets the title of the dialogue entry, which is an optional field typically only used internally by the developer. More...
 
string MenuText [get, set]
 Gets or sets the menu text, which is the text displayed when offering a list of player responses. More...
 
string DefaultMenuText [get, set]
 Gets or sets the default menu text ("Menu Text"). More...
 
string LocalizedMenuText [get, set]
 Gets or sets the localized menu text (e.g., "Menu Text LN", where LN is the current language). More...
 
string DialogueText [get, set]
 Gets or sets the dialogue text, which is the subtitle text displayed when a line is spoken. More...
 
string DefaultDialogueText [get, set]
 Gets or sets the default dialogue text ("Dialogue Text"). More...
 
string LocalizedDialogueText [get, set]
 Gets or sets the localized dialogue text ("LN", where LN is the current language). More...
 
string? SubtitleText [get]
 Gets the subtitle text, which is normally the dialogue text. More...
 
string? ResponseButtonText [get]
 Gets the response button menu text, which is normally the menu text. More...
 
string Sequence [get, set]
 Gets or sets the sequence string. More...
 
string DefaultSequence [get, set]
 Gets or sets the default, non-localized sequence ("Sequence"). More...
 
string LocalizedSequence [get, set]
 Gets or sets the localized sequence (e.g., "Sequence LN", where LN is the current language). More...
 
string ResponseMenuSequence [get, set]
 Gets or sets the response menu sequence string. More...
 
string DefaultResponseMenuSequence [get, set]
 Gets or sets the default, non-localized response menu sequence ("Response Menu Sequence"). More...
 
string LocalizedResponseMenuSequence [get, set]
 Gets or sets the localized response menu sequence (e.g., "Response Menu Sequence LN", where LN is the current language). More...
 
string VideoFile [get, set]
 Gets or sets the video file string. More...
 
string AudioFiles [get, set]
 Gets or sets the audio files string. More...
 
string AnimationFiles [get, set]
 Gets or sets the animation files string. More...
 
string LipsyncFiles [get, set]
 Gets or sets the lipsync files string. More...
 

Detailed Description

A dialogue entry is a single line of dialogue in a Conversation, with a list of links to possible responses (see Link).

The dialogue entries in a conversation form a dialogue tree, where earlier entries branch out using links to point to later entries. Technically, the conversation forms a directed graph, not a true tree, because links can also loop back to earlier entries.

A dialogue entry has a speaker (the "actor") and a listener (the "conversant").

Constructor & Destructor Documentation

◆ DialogueEntry() [1/3]

PixelCrushers.DialogueSystem.DialogueEntry.DialogueEntry ( )

Initializes a new DialogueEntry.

◆ DialogueEntry() [2/3]

PixelCrushers.DialogueSystem.DialogueEntry.DialogueEntry ( ChatMapper.DialogEntry  chatMapperDialogEntry)

Initializes a new DialogueEntry copied from a Chat Mapper DialogEntry.

Parameters
chatMapperDialogEntryThe Chat Mapper dialog entry to copy.

◆ DialogueEntry() [3/3]

PixelCrushers.DialogueSystem.DialogueEntry.DialogueEntry ( DialogueEntry  sourceEntry)

Copy constructor.

Parameters
sourceEntrySource entry.

Member Function Documentation

◆ HasResponseMenuSequence()

bool PixelCrushers.DialogueSystem.DialogueEntry.HasResponseMenuSequence ( )

Indicates whether this entry has a response menu sequence.

Returns
true if it has a response menu sequence; otherwise, false.

◆ UseCanvasRectField()

void PixelCrushers.DialogueSystem.DialogueEntry.UseCanvasRectField ( )

If the dialogue entry has a canvasRect field, extract it and use it to set the canvas rect position.

Member Data Documentation

◆ canvasRect

Rect PixelCrushers.DialogueSystem.DialogueEntry.canvasRect = new Rect(0, 0, CanvasRectWidth, CanvasRectHeight)

The position of this entry on the Dialogue Editor's node canvas.

◆ CanvasRectHeight

const float PixelCrushers.DialogueSystem.DialogueEntry.CanvasRectHeight = 30f
static

◆ CanvasRectWidth

const float PixelCrushers.DialogueSystem.DialogueEntry.CanvasRectWidth = 160f
static

◆ conditionPriority

ConditionPriority PixelCrushers.DialogueSystem.DialogueEntry.conditionPriority = ConditionPriority.Normal

The priority of the link.

In a dialogue entry, links are evaluated in priority order from High to Low.

◆ conditionsString

string PixelCrushers.DialogueSystem.DialogueEntry.conditionsString = null

A Lua conditional expression.

When evaluating links, the dialogue system will only present links whose conditions are true, empty, or null.

◆ conversationID

int PixelCrushers.DialogueSystem.DialogueEntry.conversationID = 0

The ID of the conversation that this dialogue entry belongs to.

◆ delaySimStatus

bool PixelCrushers.DialogueSystem.DialogueEntry.delaySimStatus = false

Currently unused by the dialogue system, this is the delay value to use in Chat Mapper's conversation simulator.

◆ falseConditionAction

string PixelCrushers.DialogueSystem.DialogueEntry.falseConditionAction = null

Specifies how to proceed when encountering a link whose entry's condition is false.

Valid values are "Block" and "Passthrough". If the value is "Block", no further links are considered. If the value is "Passthrough", the dialogue system ignores this link and continues evaluating the next link.

◆ fields

List<Field> PixelCrushers.DialogueSystem.DialogueEntry.fields = null

The dialogue entry's field list.

(See Field)

◆ id

int PixelCrushers.DialogueSystem.DialogueEntry.id = 0

The dialogue entry ID.

Links reference dialogue entries by ID.

◆ isGroup

bool PixelCrushers.DialogueSystem.DialogueEntry.isGroup = false

true if this entry is an empty line used to group a subtree of dialogue entries.

◆ isRoot

bool PixelCrushers.DialogueSystem.DialogueEntry.isRoot = false

true if this is the root (first) entry in a conversation; otherwise false.

◆ nodeColor

string PixelCrushers.DialogueSystem.DialogueEntry.nodeColor = null

Currently unused by the dialogue system, this is the nodeColor value defined in Chat Mapper.

◆ onExecute

UnityEngine.Events.UnityEvent PixelCrushers.DialogueSystem.DialogueEntry.onExecute = new UnityEngine.Events.UnityEvent()

◆ outgoingLinks

List<Link> PixelCrushers.DialogueSystem.DialogueEntry.outgoingLinks = new List<Link>()

The list of outgoing links from this dialogue entry.

◆ userScript

string PixelCrushers.DialogueSystem.DialogueEntry.userScript = null

Lua code to run when this dialogue entry is spoken.

If userScript is null or empty, it's ignored.

Property Documentation

◆ ActorID

int PixelCrushers.DialogueSystem.DialogueEntry.ActorID
getset

Gets or sets the ID of the line's actor (speaker).

The ID of the actor.

◆ AnimationFiles

string PixelCrushers.DialogueSystem.DialogueEntry.AnimationFiles
getset

Gets or sets the animation files string.

This field is defined in Chat Mapper, and doesn't do anything in the dialogue system. Instead, the Sequence field should contain Sequencer commands to do things like play animations.

The animation files string.

◆ AudioFiles

string PixelCrushers.DialogueSystem.DialogueEntry.AudioFiles
getset

Gets or sets the audio files string.

This field is defined in Chat Mapper but doesn't do anything in the Dialogue System. Instead, the Sequence field should contain Sequencer commands to do things like play audio.

The audio files string.

◆ ConversantID

int PixelCrushers.DialogueSystem.DialogueEntry.ConversantID
getset

Gets or sets the ID of the line's conversant (listener).

The ID of the conversant.

◆ DefaultDialogueText

string PixelCrushers.DialogueSystem.DialogueEntry.DefaultDialogueText
getset

Gets or sets the default dialogue text ("Dialogue Text").

The default dialogue text.

◆ DefaultMenuText

string PixelCrushers.DialogueSystem.DialogueEntry.DefaultMenuText
getset

Gets or sets the default menu text ("Menu Text").

The default menu text.

◆ DefaultResponseMenuSequence

string PixelCrushers.DialogueSystem.DialogueEntry.DefaultResponseMenuSequence
getset

Gets or sets the default, non-localized response menu sequence ("Response Menu Sequence").

The default response menu sequence.

◆ DefaultSequence

string PixelCrushers.DialogueSystem.DialogueEntry.DefaultSequence
getset

Gets or sets the default, non-localized sequence ("Sequence").

Note that this is different from the DialogueManager display settings Default Sequence, which is the sequence used whenever a dialogue entry doesn't have a sequence defined.

The default sequence.

◆ DialogueText

string PixelCrushers.DialogueSystem.DialogueEntry.DialogueText
getset

Gets or sets the dialogue text, which is the subtitle text displayed when a line is spoken.

The dialogue text. The actual field used depends on the current Localization. If using the default language, the field is "Dialogue Text". Otherwise the field is "LN", where LN is the current language.

◆ LipsyncFiles

string PixelCrushers.DialogueSystem.DialogueEntry.LipsyncFiles
getset

Gets or sets the lipsync files string.

This field is defined in Chat Mapper, and doesn't do anything in the Dialogue System. Instead, the videoFile field should contain Sequencer commands to do things like play lip sync animation and audio.

The lip sync files string.

◆ LocalizedDialogueText

string PixelCrushers.DialogueSystem.DialogueEntry.LocalizedDialogueText
getset

Gets or sets the localized dialogue text ("LN", where LN is the current language).

The localized dialogue text.

◆ LocalizedMenuText

string PixelCrushers.DialogueSystem.DialogueEntry.LocalizedMenuText
getset

Gets or sets the localized menu text (e.g., "Menu Text LN", where LN is the current language).

The localized menu text.

◆ LocalizedResponseMenuSequence

string PixelCrushers.DialogueSystem.DialogueEntry.LocalizedResponseMenuSequence
getset

Gets or sets the localized response menu sequence (e.g., "Response Menu Sequence LN", where LN is the current language).

The localized sequence.

◆ LocalizedSequence

string PixelCrushers.DialogueSystem.DialogueEntry.LocalizedSequence
getset

Gets or sets the localized sequence (e.g., "Sequence LN", where LN is the current language).

The localized sequence.

◆ MenuText

string PixelCrushers.DialogueSystem.DialogueEntry.MenuText
getset

Gets or sets the menu text, which is the text displayed when offering a list of player responses.

Menu text can be used to present a shortened or paraphrased version of the full dialogue text. If menuText is null, the dialogue system uses dialogueText when offering player responses.

The menu text. The actual field used depends on the current Localization. If using the default language, the field is "Menu Text". Otherwise the field is "Menu Text LN", where LN is the current language.

◆ ResponseButtonText

string? PixelCrushers.DialogueSystem.DialogueEntry.ResponseButtonText
get

Gets the response button menu text, which is normally the menu text.

If the menu text isn't assigned, the dialogue text is used.

The response button text.

◆ ResponseMenuSequence

string PixelCrushers.DialogueSystem.DialogueEntry.ResponseMenuSequence
getset

Gets or sets the response menu sequence string.

This is a custom field, and is used to specify Sequencer commands to play as the line is spoken. These sequencer commands can include animation, lip sync, audio, camera work, etc. (See sequencer)

The sequencer commands to play.

◆ Sequence

string PixelCrushers.DialogueSystem.DialogueEntry.Sequence
getset

Gets or sets the sequence string.

This is a custom field, and is used to specify Sequencer commands to play as the line is spoken. These sequencer commands can include animation, lip sync, audio, camera work, etc. (See sequencer)

The sequencer commands to play.

Prior to version 1.0.6, the Dialogue System used the VideoFile field. Use the Sequence field instead now.

◆ SubtitleText

string? PixelCrushers.DialogueSystem.DialogueEntry.SubtitleText
get

Gets the subtitle text, which is normally the dialogue text.

If the dialogue text isn't assigned, the menu text is used.

The subtitle text.

◆ Title

string PixelCrushers.DialogueSystem.DialogueEntry.Title
getset

Gets or sets the title of the dialogue entry, which is an optional field typically only used internally by the developer.

The title of the dialogue entry.

◆ VideoFile

string PixelCrushers.DialogueSystem.DialogueEntry.VideoFile
getset

Gets or sets the video file string.

This field is no longer used for cutscene sequences!

Whatever you want. This is no longer used for cutscene sequences.

Prior to version 1.0.6, the Dialogue System used this field for cutscene sequences. It now uses the custom Sequence field.


The documentation for this class was generated from the following file: