返回模组列表
在 Nexus Mods 查看
1. 将 DebugConsole.dll 和 DebugConsole.json 复制到游戏目录下的 mods 文件夹:
Slay the Spire 2/
└── mods/
├── DebugConsole.dll
└── DebugConsole.json
2. 启动游戏,控制台窗口会自动弹出
日志保存在游戏用户数据目录的 logs 文件夹下:
%AppData%/SlayTheSpire2/logs/
├── DebugConsole.log # 当前运行日志
└── DebugConsole-prev.log # 上一次运行日志
本项目基于 Alchyr/ModTemplate-StS2 模板创建。
本项目遵循原游戏的 MOD 许可政策。
1. Copy DebugConsole.dll and DebugConsole.json to the mods folder in your game directory:
Slay the Spire 2/
└── mods/
├── DebugConsole.dll
└── DebugConsole.json
2. Launch the game — the console window will open automatically
Logs are saved in the logs folder under the game's user data directory:
%AppData%/SlayTheSpire2/logs/
├── DebugConsole.log # Current session log
└── DebugConsole-prev.log # Previous session log
This project is based on the Alchyr/ModTemplate-StS2 template.
This project follows the original game's modding policy.

其他
DebugConsole
作者:MhzvV1.0.2
Real-time external console for viewing logs, with color-coded output and automatic log file saving.实时外部控制台用于查看日志,日志按级别着色并自动保存日志文件。
创建时间
2026年3月8日
更新时间
2026年6月19日
详情介绍
此模组描述由作者在 Nexus Mods 上以英文提供。
DebugConsole
游戏启动时自动弹出一个独立的控制台窗口,实时显示所有日志输出。
功能特性
- 实时日志窗口:游戏启动时自动弹出 Windows 控制台,实时滚动显示日志
- 全量日志捕获:捕获游戏 Logger 系统和 Godot 引擎的所有输出
- 颜色区分级别:Error 红色、Warn 黄色、Info 白色、Debug 灰色、引擎输出青色
- 日志文件保存:自动保存当前日志和上一次日志,崩溃后也能查看
- 无需翻文件:告别手动查看 log 文件的痛苦
安装
1. 将 DebugConsole.dll 和 DebugConsole.json 复制到游戏目录下的 mods 文件夹:
Slay the Spire 2/
└── mods/
├── DebugConsole.dll
└── DebugConsole.json
2. 启动游戏,控制台窗口会自动弹出
日志文件
日志保存在游戏用户数据目录的 logs 文件夹下:
%AppData%/SlayTheSpire2/logs/
├── DebugConsole.log # 当前运行日志
└── DebugConsole-prev.log # 上一次运行日志
技术实现
- 通过 Win32 AllocConsole 创建独立控制台窗口
- 订阅游戏全局 Log.LogCallback 事件捕获 Logger 日志
- 通过 pipe 拦截进程 stdout 捕获 Godot 引擎输出,自动去重
- 仅限 Windows 平台
致谢
本项目基于 Alchyr/ModTemplate-StS2 模板创建。
许可证
本项目遵循原游戏的 MOD 许可政策。
DebugConsole
Automatically opens an external console window on game launch to display all log output in real time.
Features
- Real-time Log Window: Automatically opens a Windows console on game launch with live scrolling logs
- Full Log Capture: Captures all output from the game's Logger system and Godot engine
- Color-coded Log Levels: Error in red, Warn in yellow, Info in white, Debug in gray, engine output in cyan
- Log File Persistence: Saves current and previous session logs, viewable even after crashes
- No More Digging Through Files: Say goodbye to manually opening log files
Installation
1. Copy DebugConsole.dll and DebugConsole.json to the mods folder in your game directory:
Slay the Spire 2/
└── mods/
├── DebugConsole.dll
└── DebugConsole.json
2. Launch the game — the console window will open automatically
Log Files
Logs are saved in the logs folder under the game's user data directory:
%AppData%/SlayTheSpire2/logs/
├── DebugConsole.log # Current session log
└── DebugConsole-prev.log # Previous session log
Technical Details
- Creates an external console window via Win32 AllocConsole
- Subscribes to the game's global Log.LogCallback event for Logger output
- Intercepts process stdout via pipe to capture Godot engine output, with automatic deduplication
- Windows only
Acknowledgments
This project is based on the Alchyr/ModTemplate-StS2 template.
License
This project follows the original game's modding policy.