refactor: NeoForge BMCLAPI 版本列表(爱来自 bangbang93)
fix: 安装 NeoForge 整合包时的参数初始化不正确 chores: 在低版本(<=1.19)的自动安装界面将不会显示 NeoForge
This commit is contained in:
@@ -1300,7 +1300,7 @@ Retry:
|
||||
Dim DownloadInfo = If(IsNeo, DownloadNeoInfo, DownloadForgeInfo)
|
||||
If IsNeo Then '兜底,有的时候 DownloadInfo 可能是空的
|
||||
If DownloadNeoInfo Is Nothing Then
|
||||
DownloadInfo.VersionName = Version
|
||||
DownloadInfo = New DlNeoForgeVersionEntry With {.VersionName = Version}
|
||||
Version = Version.Replace("neoforge-", "").Replace("-beta", "").Replace("1.20.1-", "")
|
||||
DownloadInfo.VersionCode = Version
|
||||
If Version.Contains("-beta") Then DownloadInfo.IsBeta = True
|
||||
|
||||
@@ -372,20 +372,24 @@
|
||||
LabForge.Foreground = ColorGray1
|
||||
End If
|
||||
'NeoForge
|
||||
Dim NeoForgeError As String = LoadNeoForgeGetError()
|
||||
CardNeoForge.MainSwap.Visibility = If(NeoForgeError Is Nothing, Visibility.Visible, Visibility.Collapsed)
|
||||
If NeoForgeError IsNot Nothing Then CardNeoForge.IsSwaped = True
|
||||
SetNeoForgeInfoShow(CardNeoForge.IsSwaped)
|
||||
If SelectedNeoForge Is Nothing Then
|
||||
BtnNeoForgeClear.Visibility = Visibility.Collapsed
|
||||
ImgNeoForge.Visibility = Visibility.Collapsed
|
||||
LabNeoForge.Text = If(NeoForgeError, "点击选择")
|
||||
LabNeoForge.Foreground = ColorGray4
|
||||
If Not SelectedMinecraftId.Contains("1.") OrElse Val(SelectedMinecraftId.Split(".")(1)) <= 19 Then
|
||||
CardNeoForge.Visibility = Visibility.Collapsed
|
||||
Else
|
||||
BtnNeoForgeClear.Visibility = Visibility.Visible
|
||||
ImgNeoForge.Visibility = Visibility.Visible
|
||||
LabNeoForge.Text = SelectedNeoForge.VersionCode & If(SelectedNeoForge.IsBeta, "-beta", "")
|
||||
LabNeoForge.Foreground = ColorGray1
|
||||
Dim NeoForgeError As String = LoadNeoForgeGetError()
|
||||
CardNeoForge.MainSwap.Visibility = If(NeoForgeError Is Nothing, Visibility.Visible, Visibility.Collapsed)
|
||||
If NeoForgeError IsNot Nothing Then CardNeoForge.IsSwaped = True
|
||||
SetNeoForgeInfoShow(CardNeoForge.IsSwaped)
|
||||
If SelectedNeoForge Is Nothing Then
|
||||
BtnNeoForgeClear.Visibility = Visibility.Collapsed
|
||||
ImgNeoForge.Visibility = Visibility.Collapsed
|
||||
LabNeoForge.Text = If(NeoForgeError, "点击选择")
|
||||
LabNeoForge.Foreground = ColorGray4
|
||||
Else
|
||||
BtnNeoForgeClear.Visibility = Visibility.Visible
|
||||
ImgNeoForge.Visibility = Visibility.Visible
|
||||
LabNeoForge.Text = SelectedNeoForge.VersionCode & If(SelectedNeoForge.IsBeta, "-beta", "")
|
||||
LabNeoForge.Foreground = ColorGray1
|
||||
End If
|
||||
End If
|
||||
'Fabric
|
||||
If SelectedMinecraftId.Contains("1.") AndAlso Val(SelectedMinecraftId.Split(".")(1)) <= 13 Then
|
||||
|
||||
Reference in New Issue
Block a user