Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions plugins/unity-launcher/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
## 1.0.4 - 2026-10-22
1. 编辑器导入支持选择整盘,无固定搜索深度限制,改用异步流式目录扫描。
2. 项目和编辑器扫描统一提供实时进度、取消操作、不可访问目录统计和错误反馈。
3. 移除启动和渲染时的调试日志,避免每次唤起都序列化完整项目列表。
4. 打开项目前自动刷新 `ProjectVersion.txt`,项目升级 Unity 后无需重新导入。
## 1.0.4 - 2026-11-21
1. bug修复
10 changes: 9 additions & 1 deletion plugins/unity-launcher/preload.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,20 @@ window.services = {
// ---------- 统一的分离式启动(带错误处理,避免未捕获的 'error' 事件) ----------
_spawnDetached(exePath, args) {
const fs = require('fs');
const path = require('path');
const { spawn } = require('child_process');
if (!exePath) throw new Error('未指定 Unity.exe 路径');
if (!fs.existsSync(exePath)) throw new Error(`编辑器不存在: ${exePath}`);
let child;
try {
child = spawn(exePath, args, { detached: true, stdio: 'ignore', windowsHide: true });
// Unity.exe 是 GUI 程序。windowsHide 会让旧版编辑器加载完成后仍不显示主窗口。
// 分离进程并忽略标准流即可;编辑器进程必须允许显示自己的窗口。
child = spawn(exePath, args, {
detached: true,
stdio: 'ignore',
windowsHide: false,
cwd: path.dirname(exePath)
});
} catch (e) {
throw new Error(`启动失败: ${e.message}`);
}
Expand Down
Loading