Repository navigation
fix(everest): 安装 Everest 前检查游戏是否在运行,并给文件占用的失败加恢复提示 - #89
Merged
std-microblock merged 1 commit intoOct 15, 2026
Merged
std-microblock merged 1 commit into
std-microblock merged 1 commit into
Conversation
The Everest install path downloads the package, extracts it over the game directory and then runs MiniInstaller, but it never checked whether the game was running. MiniInstaller's own guard (WaitForGameExit) is a no-op when it is launched this way and EnsureGameIsWriteable only probes Celeste.exe and Celeste.dll, so a process still holding a native library fails the install half-way through with a raw IOException on lib64-win-x64\fmod64.dll, leaving the game with a new Celeste.Mod.mm.dll but the old patched Celeste.dll. Refuse early like the local package install path does, and append an actionable hint to that file-in-use error.
std-external
force-pushed
the
fix/everest-install-require-game-closed
branch
from
October 14, 2026 13:46
98dc1e1 to
9847c03
Compare
Contributor
Author
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
问题
在 CeleMod 的 Everest 页面点「安装/更新 Everest」,如果游戏(或任何进程)还占着游戏目录里的原生库,安装会每次都在中途失败:
失败之后游戏也起不来了(下面的「影响」)。来源:群里有玩家报告,重启电脑后依旧每次失败。
原因
download_and_install_everest(src-tauri/src/backend.rs)直接下载 → 把整包解压覆盖游戏目录 →Command::new(MiniInstaller-win64.exe)(src-tauri/src/everest.rs的run_command)。同一个仓库里其它会写游戏目录的路径都有保护:本地包安装用is_celeste_running()直接拒绝,崩溃助手先调stop_game_for_restart,MiaoNet 设置用ensure_miaonet_game_stopped;只有这个命令没有。InGameUpdaterHelper.WaitForGameExit()只在游戏内更新器设置的EVEREST_UPDATE_CELESTE_PID存在时才动手;EnsureGameIsWriteable()也只探测Celeste.exe和Celeste.dll,lib64-win-x64下的原生库不在范围内,所以占用直到File.Copy才炸出来。Celeste.Mod.mm.dll+ 旧的打过补丁的Celeste.dll」的半成品状态,MiniInstaller 重建Celeste.dll/apphost 的步骤(Program.cs:99-127)都没跑到,游戏因此打不开。改动
只动
src-tauri/src/backend.rs:download_and_install_everest命令在安装前用已有的is_celeste_running()判断,游戏在跑就直接失败并提示「请先退出 Celeste 再安装 Everest」。崩溃助手路径先 kill 了游戏,不受影响;测试模式的早退分支在检查之前,也不受影响。with_file_in_use_hint():安装失败信息里出现being used by another process/另一个程序正在使用此文件时,补一句「确认游戏已完全退出(任务管理器里没有 Celeste.exe)后重新安装一次 Everest」,并说明上一次中断留下的半成品会被这次安装覆盖(这正是「安装失败后游戏打不开」的解法)。验证
EverestAPI/Everest源码逐行对应(LibAndDepHandling.cs:88/103、Program.cs:77),确认是标准模式安装器;gh release view stable-1.6623.0 --repo EverestAPI/Everest下的main.zip核对了包内路径:main/everest-lib/lib64-win-x64/fmod64.dll对应报错里的目标目录,包内没有piton-runtime/、根目录也没有FNA.dll(排除了其它几个可能的启动失败原因);cargo check: