The name of the Dialogue Branch tag you want to check.
Check if a player has visited a Dialogue Branch in the past.
The title of the branch to check for. Leaving this empty will check if the current branch title has been visited in the past.
Check if the currently parsed Dialogue branch title is a query.
The Dialogue Branch name you want to check for.
Clear the current State of the Dialogue Parser.
Get the number of command parameters in a command with parameters that has been caught by a isCommandCalled condition
Check if a specific variable created by the Dialogue parses exists and is equal to a specific value.
The name of the variable you want to check the value of
The value you want to check against
Scroll the clipped text to its end, so the entire text is printed. This can be useful in keeping the event sheet logic simpler, while supporting more variation.
Confirm the currently selected option, during the parsing of an Options type line.
This will advance the dialogue tree to the dialogue branch was selected by the player.
Get one of the current Dialogue branch tags via index.
The index of the Dialogue Branch tag you want to get.
The branch tag at the specified index, or an empty string if not found.
Get all the branch tags from the current Dialogue branch as a string. Useful for debugging.
The current branch tags, separated by a comma.
Get the entire unparsed text of the current Dialogue Branch
Get the current Dialogue Tree branch title.
The current branch title.
Get the current dialogue line with a scrolling effect (recommended).
Used with the scrollClippedText to achieve a classic scrolling text, as well as any <
Get a command parameter in any command with parameters that has been caught by a isCommandCalled condition
The index of the parameter to get.
Get the text of an option the player can select. Used with getLineOptionsCount to render options for the player when a line of the Options type is parsed
The index of the option you want to get
Get the number of options that are presented to the player, during the parsing of an Options type line.
The number of options
Get the text of the options the player can select, along with the selection cursor.
The string used to draw the currently selected option's cursor
when true each option is rendered on a new line.
Get the current complete dialogue line without using any scrolling effects.
Note that using this instead getClippedLineText will skip any <
Get the currently selected option
The index of the currently selected option
Get any tag(parameter,anotherParameter) from a tag captured by the branchContainsTag Condition
The index of the tag parameter you want to get. Leaving this empty will result in retrieving the first parameter.
Get the value of a variable stored in the dialogue state.
The variable name
Get the value of a variable stored in the dialogue state.
The variable name
Get the value of a variable stored in the dialogue state.
The variable name
Get a list of all the titles of visited by the player Branches. Useful for debugging.
This is the main lifecycle function.It runs once only when the user is advancing the dialogue to the next line.
Progress Dialogue to the next line. Hook it to your game input.
Note that this action can be influenced by any <
Check if text scrolling has completed. Useful to prevent the user from skipping to next line before the current one has been printed fully.
Check if a branch exists. It is also used internally whenever you use the start from action.
The Dialogue Branch name you want to check.
Check when the player has changed option selection since the last call to this function.
Can be used to re-render your displayed dialogue options when needed.
true if the selected option was updated since the last call to this function
Catch <
The command you want to check for being called. Write it without the <<>>
.
Check the type of the Dialogue Line that is being displayed to the player at the moment.
There are three types:
The type you want to check for ( one of the three above )
Check if the Dialogue Tree is currently parsing data. For example, you can do things like disabling player movement while talking to a NPC.
Load the Dialogue Tree data from a JSON resource.
The scene where the dialogue is running.
The JSON resource where to load the Dialogue Tree data from. The data is a JSON string usually created with Yarn Dialogue Editor.
The Dialogue Branch to start the Dialogue Tree from. If left empty, the data will only be loaded, but can later be initialized via another action
Load the Dialogue Tree data of the game. Initialize The Dialogue Tree, so as it can be used in the game.
The variable to load the Dialogue tree data from. The data is a JSON string, created by Yarn.
The Dialogue Branch to start the Dialogue Tree from. If left empty, the data will only be loaded, but can later be initialized via another action
Load the current State of the Dialogue Parser from a specified variable. Can be used to implement persistence in dialogue through your game's Load/Save function. That way you can later load all the dialogue choices the player has made.
The structured variable where to load the State from.
Store the current State of the Dialogue Parser in a specified variable. Can be used to implement persistence in dialogue through your game's Load/Save function. That way you can later load all the dialogue choices the player has made.
The variable where to store the State
Scroll the clipped text. This can be combined with a timer and user input to control how fast the dialogue line text is scrolling.
Select next option during Options type line parsing. Hook this to your game input.
Select option by index during Options type line parsing.
The index of the option to select
Select previous option during Options type line parsing. Hook this to your game input.
Set a specific variable created by the Dialogue parser to a specific value.
The name of the variable you want to set the value of
The value you want to set
Start parsing dialogue from a specified Dialogue tree branch. Can be used if you want to store multiple dialogues inside a single Dialogue tree data set.
The Dialogue Branch name you want to start parsing from.
Stop the currently running dialogue
Generated using TypeDoc
Check if the current Dialogue branch contains a specific tag.