> 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/getting-started/stack-o-bot-tutorial-setup.md).

# Stack O Bot 教程设置

构建 Convai 角色动作教程使用的示例项目，从 Epic 的免费 Stack O Bot 开始并应用 Convai 教程文件。

Convai 的 AI 玩家教程系列是在 Epic Games 免费的 Stack O Bot 示例中拍摄的，并在其上应用了一套 Convai 文件。本系列中，一名人类玩家和一名由 Convai 驱动的队友共同解决一个两人谜题，单靠任何一方都无法完成。本页将从零开始重建该项目，使你的编辑器与视频一致。只有当你想在同一场景中跟着做时才需要它；本系列涵盖的每项功能都适用于任何项目。

{% embed url="<https://youtu.be/KcJETVhI7KM>" %}
AI 玩家系列的第一部分，拍摄于此项目中
{% endembed %}

### 开始之前

* **Unreal Engine 5.8。** 教程文件是基于 5.8 准备的。使用其他引擎版本创建的项目将与教程不匹配。
* **一个 Epic Games 账户**，用于从 Fab 获取 Stack O Bot。
* **已安装 Convai 插件并配置好你的 API 密钥。** 参见 [安装 Convai 插件](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/install-the-convai-plugin.md) 和 [配置你的 API 密钥](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/configure-your-api-key.md).

{% hint style="info" %}
Stack O Bot 由 Epic Games 发布，并且是免费的。Convai 教程文件是单独下载的内容，只会添加教程使用的地图、蓝图和配置。
{% endhint %}

### 创建 Stack O Bot 项目

{% stepper %}
{% step %}

#### 在 Fab 上获取 Stack O Bot

打开 [Fab 上的 Stack O Bot](https://www.fab.com/listings/b4dfff49-0e7d-4c4b-a6c5-8a0315831c9c)，使用你的 Epic Games 账户登录，然后选择 **添加到我的库**。如有提示，请接受许可协议。

<figure><img src="https://2402152281-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2Fkms4ACNuh5z7r2lWpEOq%2Fimage.png?alt=media&amp;token=87fe257b-637c-4294-813d-9fd2400f13fe" alt="The Stack O Bot listing on Fab, showing the Add to My Library button"><figcaption><p>Stack O Bot 是免费的，并由 Epic Games 发布。</p></figcaption></figure>
{% endstep %}

{% step %}

#### 从 Epic Games 启动器创建项目

打开 Epic Games 启动器并前往 **Unreal Engine > Library > Fab Library**。找到 **Stack O Bot**，选择 **创建项目**，并选择 Unreal Engine 5.8。
{% endstep %}

{% step %}

#### 记下项目位置

在创建项目之前，复制或写下项目文件夹。你在下一节中需要这个路径，而启动器之后不会再次显示它。
{% endstep %}
{% endstepper %}

### 应用 Convai 教程文件

教程文件是一个差异包：它只包含为 Convai 教程新增或修改的内容，准备复制到你上面创建的项目中。

{% stepper %}
{% step %}

#### 下载教程文件

从以下位置下载 Convai Stack O Bot 教程差异包： [Convai 教程差异包下载](https://drive.google.com/uc?export=download\&id=1RvlntYxX_Q-pr7Q_O0jYwhzrmob1WEgd)。该压缩包包含一个 `Content` 文件夹和一个 `Config` 文件夹。
{% endstep %}

{% step %}

#### 解压压缩包

右键单击下载的 ZIP，选择 **全部解压**，并打开解压后的文件夹。确认你能看到 `Content` 和 `Config` 直接位于其中。
{% endstep %}

{% step %}

#### 将差异包复制到项目中

打开你之前记录的 Stack O Bot 项目文件夹。将解压文件夹内的所有内容复制到项目文件夹中，并在 Windows 提示时选择 **位于** 解压文件夹内的内容复制到项目文件夹中，并选择 **替换目标中的文件** 。
{% endstep %}
{% endstepper %}

{% hint style="warning" %}
复制的是差异包文件夹中的内容，而不是文件夹本身。复制正确时， `Content` 和 `Config` 应直接位于 `StackOBot.uproject`旁边。嵌套的额外文件夹是地图不显示的最常见原因。
{% endhint %}

### 打开并测试项目

{% stepper %}
{% step %}

#### 打开项目

打开 `StackOBot.uproject` 并使用 Unreal Engine 5.8。如果编辑器询问是否重建模块，请允许。
{% endstep %}

{% step %}

#### 登录 Convai

打开 Convai 编辑器窗口并登录。参见 [登录并管理你的账户](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/editor-window/sign-in-and-manage-your-account.md).
{% endstep %}

{% step %}

#### 播放教程关卡

打开 `Content/StackOBot/Maps/Convai/Lvl_Convai` 并按 **播放**.
{% endstep %}
{% endstepper %}

### 验证设置

当以下情况出现时，项目就准备好了： `Lvl_Convai` 出现在 **内容浏览器** 在以下位置 `Content/StackOBot/Maps/Convai`中，关卡打开时没有缺少资源的警告，并且在播放模式下与 Convai 角色对话时它会作出回应。

如果地图缺失，说明差异包复制得比预期深了一层——请检查 `Content` 和 `Config` 应位于 `StackOBot.uproject` 而不是另一个文件夹内。如果地图能打开但角色没有回应，则说明插件已安装但未通过身份验证；请按照 [配置你的 API 密钥](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/configure-your-api-key.md).

### 下一步

在示例项目运行后，按照它拍摄时的场景继续本系列。第一部分将 AI 队友带入关卡，启用动作，并标记压力板和移动平台；第二部分为箱子添加自定义拾取和放下动作。以下页面以文字形式涵盖相同内容。

{% content-ref url="/pages/e40e8b0853ec91418830a025e7b0c9acccd8d371" %}
[角色动作快速入门](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/character-actions/character-actions-quick-start.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 dynamically by asking a question.

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

```
GET https://docs.convai.com/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/stack-o-bot-tutorial-setup.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
