> For the complete documentation index, see [llms.txt](https://docs.convai.com/api-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.convai.com/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design.md).

# 叙事设计

通过调用叙事触发器、注入模板键以及处理区段变化事件，从 Unreal Engine 驱动角色故事图。

叙事设计为 Convai 角色提供一个结构化的故事图谱——命名的章节、命名的触发器，以及会根据实时游戏数据调整目标的模板键。你在 Convai 仪表板中编写该图谱；在运行时， `UConvaiChatbotComponent` (`Convai 聊天机器人`) 调用触发器并接收来自 Convai 的章节变更。

**第一次接触叙事设计？** 先从 [叙事设计如何工作](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/how-narrative-design-works.md) 以了解章节、触发器和模板键。然后按照 [叙事设计快速入门](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/narrative-design-quick-start.md) 在你拥有一个已在仪表板中配置好图谱的角色之后。使用 [叙事设计 | Playground](/api-docs/zh/convai-playground/character-customization/narrative-design.md) 在打开 Unreal Engine 之前创建章节和触发器。

### 开始使用

<table data-view="cards"><thead><tr><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>叙事设计如何工作</strong><br>了解章节、触发器、模板键，以及从触发器调用到章节事件的运行时流程。</td><td><a href="/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/how-narrative-design-works.md">叙事设计的工作原理</a></td></tr><tr><td><strong>叙事设计快速入门</strong><br>在 Blueprint 中调用一个命名触发器，并通过打印新的章节 ID 来确认章节变更。</td><td><a href="/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/narrative-design-quick-start.md">叙事设计快速开始</a></td></tr></tbody></table>

### 构建并配置

<table data-view="cards"><thead><tr><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>叙事触发器</strong><br>使用 <code>调用叙事设计触发器</code> 用于命名的图谱转换，以及 <code>调用语音</code> 用于动态上下文事件。</td><td><a href="/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/narrative-triggers.md">叙事触发器</a></td></tr><tr><td><strong>模板键</strong><br>填充 <code>叙事模板键</code> 映射，以便章节目标引用实时游戏数值。</td><td><a href="/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/template-keys.md">模板键</a></td></tr><tr><td><strong>获取叙事数据</strong><br>在运行时使用 <code>Convai 获取叙事章节</code> 和 <code>Convai 获取叙事触发器</code>.</td><td><a href="/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/fetching-narrative-data.md">获取叙事数据</a></td></tr></tbody></table>

### 参考资料与支持

<table data-view="cards"><thead><tr><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>叙事设计 Blueprint 参考</strong><br>Blueprint 函数、事件、属性、异步获取节点以及叙事结构体的参考文档。</td><td><a href="/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/narrative-design-blueprint-reference.md">叙事设计 Blueprint 参考</a></td></tr><tr><td><strong>叙事设计使用示例</strong><br>用于线性推进、动态上下文事件、模板键和触发器验证的 Blueprint 实例教程。</td><td><a href="/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/narrative-design-usage-examples.md">叙事设计使用示例</a></td></tr><tr><td><strong>排查叙事设计问题</strong><br>修复未触发的章节事件、错误的转换、被忽略的模板键、获取失败以及会话就绪问题。</td><td><a href="/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/troubleshoot-narrative-design.md">排查叙事设计问题</a></td></tr></tbody></table>

### 下一步

{% content-ref url="/pages/fc5915683cbb3a9ae3782e4de53c3288e9e3b7cc" %}
[叙事设计快速开始](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design/narrative-design-quick-start.md)
{% endcontent-ref %}

{% content-ref url="/pages/55f4d0a125ab988f4603436fa20ceb69b527078d" %}
[叙事设计](/api-docs/zh/convai-playground/character-customization/narrative-design.md)
{% endcontent-ref %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.convai.com/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/narrative-design.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
