> For the complete documentation index, see [llms.txt](https://docs.decentraland.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.decentraland.org/creator/content-creator-zh/chang-jing-sdk7/tiao-shi/debug-in-prod.md).

# 在生产环境中调试

如何调试正在 Decentraland 中运行的场景

当运行一个已经部署到 Decentraland 土地上的场景时，你可以尝试多种方法来调试它。

## 部署前

### 预览

在将你的场景部署到 Decentraland 之前，请确保该场景使用最新版本的 Decentraland SDK 在预览中运行良好。参见 [在预览中调试](/creator/content-creator-zh/chang-jing-sdk7/tiao-shi/debug-in-preview.md).

## 快速重载

如果你需要重新加载你当前站立的场景，请在聊天中输入以下内容并按回车：

`/reload`

## 关于发布流程

请注意，每次发布后，都会有一个内部流程在所有 3D 模型可渲染之前对其进行优化。这通常只需几秒钟，但对于非常大的场景或服务器繁忙时可能会更久。在完成之前，玩家看到的仍是你场景的上一个版本。

你可以使用以下方式查看你的场景中此流程的当前状态 [此工具](https://decentraland.github.io/opscli/)。如果转换完成，资源的三种变体都应该显示绿灯。

## 场景日志

在正常使用 Decentraland 时，无法打开控制台来查看调试信息。要启用控制台，你必须使用以下参数打开 decentraland： `scene-console` 参数。然后你可以按键盘上的反引号键来切换控制台： **\`**。在大多数英文键盘上，这个键位于 1 键左侧。

要使用以下方式打开 Decentraland： `scene-console` 参数，可以通过以下任一方式：

* 将以下深链接输入浏览器窗口： `decentraland://?position=0,0&scene-console=true`。如果你已安装 Decentraland 桌面应用程序，这将会打开它。
* 在命令行中输入以下内容：
  * **macOS**: `open Decentraland.app --args --position 0,0 --scene-console true`
  * **Windows**: `"C:\Users\[YOUR-USER]\Downloads\Decentraland_windows64\Decentraland.exe" --position 0,0 --scene-console true`

{% hint style="info" %}
**💡 提示**：将 **位置** 参数更改为你场景的坐标，以便直接加载进入你的场景。
{% endhint %}

使用以下方式运行 Decentraland 时： `scene-console`，你可以通过三种方式打开控制台：

* 点击 ![](https://2460066822-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FoPnXBby9S6MrsW83Y9qZ%2Fuploads%2Fgit-blob-a673f6b987216e9e471fdac882879c44fcf94652%2Fconsole-icon.png?alt=media) 右上角的图标
* 按下 **\`** 键可打开简洁版控制台
* 按下 Shift + **\`** 以打开更大视图的控制台

请注意，每个活动场景中的消息都会记录到控制台，因此你在控制台中看到的某些内容可能与你的场景无关。

## 报告错误

如果你遇到的问题不是你的场景本身的问题，而是 Decentraland SDK 的一般问题，请参阅 [报告错误](/creator/content-creator-zh/chang-jing-sdk7/tiao-shi/report-bug.md).


---

# 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.decentraland.org/creator/content-creator-zh/chang-jing-sdk7/tiao-shi/debug-in-prod.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.
