Make source comments and build tools self-contained
This commit is contained in:
1 parent
4a2f1c120c
commit
5df305e2f9
106 files changed
+152
-183
No files matched your search
@@ -8,6 +8,7 @@
|
||||
|
||||
| 目录 | 内容 |
|
||||
|---|---|
|
||||
| `apps/launcher/` | Electron 安装器与启动器 |
|
||||
| `apps/server/` | 本地服务器(TypeScript):模拟 Gaijin 的登录、档案、匹配、商店等服务器 |
|
||||
| `packages/` | 共用的 TypeScript 库(npm workspace):BLK 编解码(`blk`)、数据包读写(`vromfs`)、JSONC(`jsonc`)、exe 补丁引擎(`exepatch`)、构建游戏副本(`patcher`) |
|
||||
| `patches/exe/` | exe 补丁定义 |
|
||||
@@ -15,3 +16,31 @@
|
||||
| `native/` | 网络钩子与本地对局模块 `wto_ws.dll`(C) |
|
||||
| `scripts/` | 开发用的 TypeScript 脚本(如 `build-game-copy.ts` 构建游戏副本) |
|
||||
| `tools/` | Python 开发端工具:数据包读写、exe 补丁核对(特征码生成、汇编核对)、界面补丁编译检查 |
|
||||
|
||||
## 本地构建
|
||||
|
||||
在 Windows 上使用 Node.js 24 或更新版本,以及 Visual Studio 的 x64 C++ 构建工具。在仓库根目录安装依赖并生成本地库。
|
||||
|
||||
```powershell
|
||||
npm install
|
||||
powershell -NoProfile -File native\wto-net\build.ps1
|
||||
```
|
||||
|
||||
从已安装的游戏读取原版文件,将生成的文件写入独立副本。两个命令使用相同的数据目录和端口。
|
||||
|
||||
```powershell
|
||||
node scripts/build-game-copy.ts --game "<原版游戏目录>" --out "<离线副本目录>" --data "<数据目录>" --port 27015
|
||||
node apps/server/src/cli.ts --game "<离线副本目录>" --data "<数据目录>" --port 27015
|
||||
```
|
||||
|
||||
## 开发检查
|
||||
|
||||
使用 `npm run typecheck` 检查 TypeScript。启动器在 `apps/launcher/` 中运行 `npm run typecheck` 和 `npm run build`。
|
||||
|
||||
使用 Python 3.12 或更新版本安装本地工具 `python -m pip install -e ./tools`。以下命令读取目标版本的原版文件。界面检查的 `--sq` 指定 Quirrel 编译器路径。
|
||||
|
||||
```powershell
|
||||
wtotools check-patches --exe "<原版游戏目录>\win64\aces.exe"
|
||||
wtotools check-gui --gui "<原版游戏目录>\gui.vromfs.bin" --sq "<Quirrel 编译器路径>"
|
||||
wtotools check-offsets --exe "<原版游戏目录>\win64\aces.exe"
|
||||
```
|
||||
Reference in new issue
Block a user