# Shadow Lines

In Yarn Spinner Scripts, **shadow lines** let you reuse the same line in multiple places, without having to create duplicate copies.

{% hint style="info" %}
Shadow lines are copies of other lines, but don’t create a duplicate entry in the string table.

This can be useful if you want to re-use an existing line in more than one place, which can be important when each line has in-game assets like voice-over recording.
{% endhint %}

Shadow lines are marked using the `#shadow:` hashtag. When you use the `#shadow:` tag, you specify the line ID of another line, which is called the source line. The source line must have an explicit `#line:` hashtag to identify it.

Here’s a simple example of using shadow lines:

```
title: Tavern
---
Ava: Hello, barkeep!  
Guy: Hi there, how can I help? 
Ava: I should go. #line:departure
===

title: Kitchen
---
Ava: Greetings, chef!
Guy: What are you doing back here? 
Ava: I should go. #shadow:departure
===
```

The script contains six lines, but only 5 string table entries will be created, because the line *“I should go”* is shadowed.

Shadow lines are required to have the same text in the Yarn script as their source line, but are allowed to have different hashtags (in addition to the `#shadow:` and `#line:` hashtags).


---

# 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/write-yarn-scripts/advanced-scripting/shadow-lines.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.
