LinePresenterButtonHandler
An ActionMarkupHandler that provides the little advance button on the built in LinePresenter prefab.
public class LinePresenterButtonHandler : ActionMarkupHandlerInherits from Yarn.Unity.ActionMarkupHandler
Implements Yarn.Unity.IActionMarkupHandler
Is an ActionMarkupHandler so that it can configure itself correctly for when
#Methods
#OnCharacterWillAppear(int, MarkupParseResult, CancellationToken)
Called repeatedly for each visible character in the line.
public override YarnTask OnCharacterWillAppear(int currentCharacterIndex, MarkupParseResult line, CancellationToken cancellationToken)Parameters
currentCharacterIndexintThe zero-based index of the character being displayed.text(unknown)ATMP_Textobject that the line is being displayed in.cancellationTokenCancellationTokenA cancellation token representing whether the
Returns YarnTask: A task that completes when the ActionMarkupHandler has completed presenting this
character. Dialogue presenters will wait until this task is complete
before displaying the remainder of the line.
This method is a ActionMarkupHandler
object's main opportunity to take action during line
display.
#OnLineDisplayBegin(MarkupParseResult, TMP_Text)
Called immediately before the first character in the line is
presented.
public override void OnLineDisplayBegin(MarkupParseResult line, TMP_Text text)Parameters
- The line being presented.
textTMP_TextATMP_Textobject that the line is being displayed in.
#OnLineDisplayComplete()
Called after the last call to
PresentCharacter(int, TMP_Text, CancellationToken).public override void OnLineDisplayComplete()This method is an opportunity for a ActionMarkupHandler to finalise its presentation after
all of the characters in the line have been presented.
#OnLineWillDismiss()
public override void OnLineWillDismiss()#OnPrepareForLine(MarkupParseResult, TMP_Text)
public override void OnPrepareForLine(MarkupParseResult line, TMP_Text text)Parameters
textTMP_Text
Generated from Yarn Spinner for Unity 3.3.