Merge pull request #4401 from tmdakm/main

读取MCBBS整合包文件中的Jvm和Launch参数
This commit is contained in:
龙腾猫跃
2025-05-29 23:08:49 +08:00
committed by GitHub
@@ -702,6 +702,14 @@ Retry:
PathMcFolder & "versions\" & VersionName, PathMcFolder & "versions\" & VersionName,
Task, 0.4) Task, 0.4)
End Sub) With {.ProgressWeight = New FileInfo(FileAddress).Length / 1024 / 1024 / 6, .Block = False}) '每 6M 需要 1s End Sub) With {.ProgressWeight = New FileInfo(FileAddress).Length / 1024 / 1024 / 6, .Block = False}) '每 6M 需要 1s
If Json("launchInfo") Is Nothing Then
Log("[ModPack] 整合包中未找到启动信息,已跳过")
Else
Dim launchArgument As String = String.Join(" ", Json("launchInfo")("launchArgument"))
Dim javaArgument As String = String.Join(" ", Json("launchInfo")("javaArgument"))
WriteIni(PathMcFolder & "versions\" & VersionName & "\PCL\Setup.ini", "VersionAdvanceJvm", javaArgument)
WriteIni(PathMcFolder & "versions\" & VersionName & "\PCL\Setup.ini", "VersionAdvanceGame", launchArgument)
End If
'构造加载器 '构造加载器
If Json("addons") Is Nothing Then Throw New Exception("该 MCBBS 整合包未提供游戏版本附加信息,无法安装!") If Json("addons") Is Nothing Then Throw New Exception("该 MCBBS 整合包未提供游戏版本附加信息,无法安装!")
Dim Addons As New Dictionary(Of String, String) Dim Addons As New Dictionary(Of String, String)