# DialogueTask

Property in [DialogueRunner](/api/csharp/yarn.unity/yarn.unity.dialoguerunner.md)

## Summary

Gets a [YarnTask](/api/csharp/yarn.unity/yarn.unity.yarntask-1.md) that completes when the dialogue runner finishes its dialogue.

```csharp
public YarnTask DialogueTask { get; }
```

## Remarks

If the dialogue is not currently running when this property is accessed, the property returns a task that is already complete.


---

# 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/api/csharp/yarn.unity/yarn.unity.dialoguerunner/yarn.unity.dialoguerunner.dialoguetask.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.
