在选择磁盘根目录作为游戏目录时弹出警告#6203
Conversation
|
en? |
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces a warning dialog when users attempt to set the disk root directory as their game folder, adding corresponding localization strings. However, the implementation introduces several critical issues: a potential NullPointerException when resolving relative paths, thread blocking and leak risks due to waiting on a CompletableFuture in a background thread, and unnecessary thread switching since the actual save logic is still dispatched back to the JavaFX thread. The reviewer recommends refactoring the save logic to run entirely on the JavaFX main thread using standard callbacks, which simplifies the code and resolves these safety and performance concerns.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
|
建议在选择磁盘根目录作为游戏目录时,自动将游戏目录更改为 .minecraft 文件夹。如果 .minecraft 已经存在,则回退到 .minecraft.1,.2, .3…… |
使用磁盘根目录作为游戏文件夹可能会导致无法启动游戏