Skip to content

Commit f8b4e9b

Browse files
fix(comp): 自动下载前置模组时文件名遵守“文件名格式”设置 (#3326)
* fix(comp): 自动下载前置模组时文件名遵守“文件名格式”设置 (#3283) * Update Plain Craft Launcher 2/Modules/Minecraft/ModCompDependency.cs Co-authored-by: 墨渊 <m56042764@163.com> --------- Co-authored-by: 墨渊 <m56042764@163.com>
1 parent 9faa457 commit f8b4e9b

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

Plain Craft Launcher 2/Modules/Minecraft/ModCompDependency.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,8 +203,9 @@ public static List<InstalledModIdentity> ScanInstalledMods(string targetModsFold
203203
continue;
204204
}
205205

206-
var targetPath = Path.Combine(targetModsFolder ?? string.Empty, ModComp.CompFileNameGet(depProject, depCompFile));
207-
downloads.Add((depCompFile.FileName, depCompFile.ToNetFile(targetPath)));
206+
var depFileName = ModComp.CompFileNameGet(depProject, depCompFile);
207+
var targetPath = Path.Combine(targetModsFolder ?? string.Empty, depFileName);
208+
downloads.Add((depFileName, depCompFile.ToNetFile(targetPath)));
208209
}
209210

210211
return downloads;

0 commit comments

Comments
 (0)