# LineAdvancer

Class in [Yarn.Unity](/3.1/api/csharp/yarn.unity.md)

Inherits from [`DialoguePresenterBase`](/3.1/api/csharp/yarn.unity/yarn.unity.dialoguepresenterbase.md)

## Summary

A dialogue presenter that listens for user input and sends requests to a [DialogueRunner](/3.1/api/csharp/yarn.unity/yarn.unity.dialoguerunner.md) to advance the presentation of the current line, either by asking a dialogue runner to hurry up its delivery, advance to the next line, or cancel the entire dialogue session.

```csharp
public sealed class LineAdvancer : DialoguePresenterBase, IActionMarkupHandler
```

## Enums

| Name                                                                                                 | Description                                            |
| ---------------------------------------------------------------------------------------------------- | ------------------------------------------------------ |
| [InputMode](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.inputmode.md) | The type of input that this line advancer responds to. |

## Fields

| Name                                                                                                                                                     | Description                                                                                                                               |
| -------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
| [advanceRequestsBeforeCancellingLine](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.advancerequestsbeforecancellingline.md) | The number of times that a 'hurry up' signal occurs before the line advancer requests that the next line be shown.                        |
| [multiAdvanceIsCancel](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.multiadvanceiscancel.md)                               | If `true` , repeatedly signalling that the line should be hurried up will cause the line advancer to request that the next line be shown. |

## Methods

| Name                                                                                                                                                                  | Description                                                                                                         |
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------- |
| [OnCharacterWillAppear(int,MarkupParseResult,CancellationToken)](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.oncharacterwillappear.md) |                                                                                                                     |
| [OnDialogueCompleteAsync()](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.ondialoguecompleteasync.md)                                    | Called by a dialogue runner when dialogue ends to remove the input action handlers.                                 |
| [OnDialogueStartedAsync()](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.ondialoguestartedasync.md)                                      | Called by a dialogue runner when dialogue starts to add input action handlers for advancing the line.               |
| [OnLineDisplayBegin(MarkupParseResult,TMP\_Text)](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.onlinedisplaybegin.md)                   |                                                                                                                     |
| [OnLineDisplayComplete()](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.onlinedisplaycomplete.md)                                        |                                                                                                                     |
| [OnLineWillDismiss()](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.onlinewilldismiss.md)                                                |                                                                                                                     |
| [OnPrepareForLine(MarkupParseResult,TMP\_Text)](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.onprepareforline.md)                       |                                                                                                                     |
| [RequestDialogueCancellation()](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.requestdialoguecancellation.md)                            | Requests that the dialogue runner to instruct all line views to dismiss their content, and then stops the dialogue. |
| [RequestLineHurryUp()](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.requestlinehurryup.md)                                              | Requests that the line be hurried up.                                                                               |
| [RequestNextLine()](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.requestnextline.md)                                                    | Requests that the dialogue runner proceeds to the next line.                                                        |
| [RequestOptionHurryUp()](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.requestoptionhurryup.md)                                          |                                                                                                                     |
| [RunLineAsync(LocalizedLine,LineCancellationToken)](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.runlineasync.md)                       | Called by a dialogue presenter to signal that a line is running.                                                    |
| [RunOptionsAsync(DialogueOption\[\],LineCancellationToken)](/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer/yarn.unity.lineadvancer.runoptionsasync.md)            | Called by a dialogue presenter to signal that options are running.                                                  |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.yarnspinner.dev/3.1/api/csharp/yarn.unity/yarn.unity.lineadvancer.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
