Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Method in Dialogue
Starts, or continues, execution of the current Program.
This method repeatedly executes instructions until one of the following conditions is encountered:
The LineHandler or CommandHandler is called. After calling either of these handlers, the Dialogue will wait until Continue() is called. Continue may be called from inside the LineHandler or CommandHandler, or may be called at any future time.
The OptionsHandler is called. When this occurs, the Dialogue is waiting for the user to specify which of the options has been selected, and SetSelectedOption(int) must be called before Continue() is called again.)
The Program reaches its end. When this occurs, SetNode(string) must be called before Continue() is called again.
An error occurs while executing the Program.
This method has no effect if it is called while the Dialogue is currently in the process of executing instructions.
LineHandler: Represents the method that is called when the Dialogue delivers a Line .
OptionsHandler: Represents the method that is called when the Dialogue delivers an OptionSet .
CommandHandler: Represents the method that is called when the Dialogue delivers a Command .
NodeCompleteHandler: Represents the method that is called when the Dialogue reaches the end of a node.
DialogueCompleteHandler: Represents the method that is called when the dialogue has reached its end, and no more code remains to be run.
Method in Dialogue
Returns the string ID that contains the original, uncompiled source text for a node.
A node's source text will only be present in the string table if its tags
header contains rawText
.
Because the Dialogue class is designed to be unaware of the contents of the string table, this method does not test to see if the string table contains an entry with the line ID. You will need to test for that yourself.
string
nodeName
The name of the node.
The string ID.
Class in Yarn
Inherits from System.Object
Co-ordinates the execution of Yarn programs.
The node that execution will start from.
Starts, or continues, execution of the current Program.
Returns the string ID that contains the original, uncompiled source text for a node.
Returns the tags for the node nodeName
.
Gets a value indicating whether nodeName
is the name of a valid node group in the program.
Gets a value indicating whether a specified node exists in the Program.
Evaluate the value of a smart variable named name
.
Unloads all nodes from the Dialogue.
Gets the name of the node that this Dialogue is currently executing.
Gets a value indicating whether the Dialogue is currently executing Yarn instructions.
Invoked when the Dialogue needs to report debugging information.
Invoked when the Dialogue needs to report an error.
Gets the names of the nodes in the currently loaded Program.
Gets or sets the object that provides access to storing and retrieving the values of variables.
Method in
Prepares the that the user intends to start running a node.
After this method is called, you call to start executing it.
If has been set, it may be called when this method is invoked, as the Dialogue determines which lines may be delivered during the startNode
node's execution.
Method in
Signals to the that the user has selected a specified .
After the Dialogue delivers an , this method must be called before is called.
The ID number that should be passed as the parameter to this method should be the field in the that represents the user's selection.
: Represents the method that is called when the Dialogue delivers an .
: A set of s, sent from the to the game.
: Starts, or continues, execution of the current Program.
Initializes a new instance of the class.
Queries the for what content could possibly run if the node group nodeGroup was run.
Prepares the that the user intends to start running a node.
Loads all nodes from the provided .
Signals to the that the user has selected a specified .
Immediately stops the .
Gets or sets the that is called when a command is to be delivered to the game.
Gets or sets the content saliency strategy used by this .
Gets or sets the that is called when the dialogue reaches its end.
Gets the that this Dialogue uses to locate functions.
Gets or sets the that is called when a line is ready to be shown to the user.
Gets or sets the that is called when a node is complete.
Gets or sets the that is called when a node is started.
Gets or sets the that is called when a set of options are ready to be shown to the user.
Gets or sets the that is called when the dialogue anticipates delivering some lines.
string
nodeName
The name of the node group to check.
string
startNode
The name of the node that will be run. The node have been loaded by calling SetProgram(Program) or AddProgram(Program)
.
string
nodeName
The name of the node.
string
nodeName
The name of the node.
Yarn.Program program
The Program to use.
int
selectedOptionID
The ID number of the Option that the user selected.
Method in Dialogue
Queries the Dialogue for what content could possibly run if the node group nodeGroup was run.
This method evaluates all nodes in the given node group, and returns a ContentSaliencyOption object for each node. This object contains the current number of passing and failing 'when' clauses on the node, as well as the complexity score for that node. This is the same information that's passed to a IContentSaliencyStrategy object's QueryBestContent(IEnumerable<ContentSaliencyOption>) method. This method is read-only, and calling it will not modify any variable state.
Note that this method does not filter its output, and may include content options whose FailingConditionValueCount is greater than zero. It's up to the caller of this function to filter out these options if they're not wanted.
This method can be used to see if any content will appear when a given node group is run. If the collection returned by this method is empty, then running this node group will not result in any content. This can be used, for example, to decide whether to show a 'character can be spoken to' indicator. You can also examine the individal ContentSaliencyOption objects to see if any content is available that passes a filter, such as whether content might appear that has a user-defined 'plot critical' tag.
string
nodeGroup
The name of the node group to get available content for.
A collection of ContentSaliencyOption objects that may appear if and when the node group nodeGroup
is run.
Method in Dialogue
Evaluate the value of a smart variable named name
.
string
name
The name of the variable.
T
result
On return, contains the returned value of the smart variable, or the default
value of T
if a smart variable named name
could not be found or its value could not be returned as type T
.
T
The type of the returned value.
true
if the smart variable was evaluated, false
otherwise.
Property in Dialogue
Gets or sets the content saliency strategy used by this Dialogue .
A content saliency strategy is a class that implements IContentSaliencyStrategy and selects the most appropriate content in a line group, or any other situation where content saliency is relevant.
Property in Dialogue
Gets or sets the CommandHandler that is called when a command is to be delivered to the game.
Property in Dialogue
Gets the name of the node that this Dialogue is currently executing.
If Continue() has never been called, this value will be null
.
Property in Dialogue
Gets or sets the DialogueCompleteHandler that is called when the dialogue reaches its end.
Property in
Gets or sets the that is called when a set of options are ready to be shown to the user.
The Options Handler delivers an to the game. Before can be called to resume execution, must be called to indicate which was selected by the user. If is not called, an exception is thrown.