2.12.1
This commit is contained in:
@@ -126,7 +126,8 @@
|
|||||||
Try
|
Try
|
||||||
'下载
|
'下载
|
||||||
NetDownloadByLoader(
|
NetDownloadByLoader(
|
||||||
If(FallbackSource?.StartsWithF("http") AndAlso Source <> FallbackSource, {Source, FallbackSource}, {Source}),
|
If(FallbackSource IsNot Nothing AndAlso FallbackSource.StartsWithF("http") AndAlso Source <> FallbackSource,
|
||||||
|
{Source, FallbackSource}, {Source}),
|
||||||
TempPath, SimulateBrowserHeaders:=True)
|
TempPath, SimulateBrowserHeaders:=True)
|
||||||
ActualSource = TempPath
|
ActualSource = TempPath
|
||||||
If Not EnableCache Then File.Delete(TempPath)
|
If Not EnableCache Then File.Delete(TempPath)
|
||||||
|
|||||||
@@ -118,6 +118,12 @@ Public Class FormMain
|
|||||||
'3:BUG+ IMP* FEAT-
|
'3:BUG+ IMP* FEAT-
|
||||||
'2:BUG* IMP-
|
'2:BUG* IMP-
|
||||||
'1:BUG-
|
'1:BUG-
|
||||||
|
If LastVersion < 378 Then 'Snapshot 2.12.1
|
||||||
|
If LastVersion >= 377 Then
|
||||||
|
FeatureList.Add(New KeyValuePair(Of Integer, String)(1, "修复:在版本列表中存在 OptiFine 时可能无法加载版本列表"))
|
||||||
|
BugCount += 2
|
||||||
|
End If
|
||||||
|
End If
|
||||||
If LastVersion < 377 Then 'Snapshot 2.12.0
|
If LastVersion < 377 Then 'Snapshot 2.12.0
|
||||||
If LastVersion >= 373 Then
|
If LastVersion >= 373 Then
|
||||||
FeatureList.Add(New KeyValuePair(Of Integer, String)(5, "删除:暂时隐藏联机入口……不过只是暂时关闭,它还会回来的!"))
|
FeatureList.Add(New KeyValuePair(Of Integer, String)(5, "删除:暂时隐藏联机入口……不过只是暂时关闭,它还会回来的!"))
|
||||||
@@ -125,8 +131,8 @@ Public Class FormMain
|
|||||||
FeatureList.Add(New KeyValuePair(Of Integer, String)(3, "新增:适配新的 Minecraft 版本号系统与 Unobfuscated 版本"))
|
FeatureList.Add(New KeyValuePair(Of Integer, String)(3, "新增:适配新的 Minecraft 版本号系统与 Unobfuscated 版本"))
|
||||||
FeatureList.Add(New KeyValuePair(Of Integer, String)(2, "优化:巨幅优化各个下载页面和 Mod 管理页面的性能"))
|
FeatureList.Add(New KeyValuePair(Of Integer, String)(2, "优化:巨幅优化各个下载页面和 Mod 管理页面的性能"))
|
||||||
FeatureList.Add(New KeyValuePair(Of Integer, String)(1, "优化:更换披风时会显示当前使用的披风"))
|
FeatureList.Add(New KeyValuePair(Of Integer, String)(1, "优化:更换披风时会显示当前使用的披风"))
|
||||||
FeatureCount += 31
|
FeatureCount += 33
|
||||||
BugCount += 27
|
BugCount += 29
|
||||||
End If
|
End If
|
||||||
If LastVersion < 375 Then 'Snapshot 2.11.2
|
If LastVersion < 375 Then 'Snapshot 2.11.2
|
||||||
'If LastVersion >= 373 Then
|
'If LastVersion >= 373 Then
|
||||||
|
|||||||
@@ -14,13 +14,13 @@ Public Module ModBase
|
|||||||
#Region "声明"
|
#Region "声明"
|
||||||
|
|
||||||
'下列版本信息由更新器自动修改
|
'下列版本信息由更新器自动修改
|
||||||
Public Const VersionBaseName As String = "2.12.0" '不含分支前缀的显示用版本名
|
Public Const VersionBaseName As String = "2.12.1" '不含分支前缀的显示用版本名
|
||||||
Public Const VersionStandardCode As String = "2.12.0." & VersionBranchCode '标准格式的四段式版本号
|
Public Const VersionStandardCode As String = "2.12.1." & VersionBranchCode '标准格式的四段式版本号
|
||||||
Public Const CommitHash As String = "" 'Commit Hash,由 GitHub Workflow 自动替换
|
Public Const CommitHash As String = "" 'Commit Hash,由 GitHub Workflow 自动替换
|
||||||
#If BETA Then
|
#If BETA Then
|
||||||
Public Const VersionCode As Integer = 372 'Release
|
Public Const VersionCode As Integer = 372 'Release
|
||||||
#Else
|
#Else
|
||||||
Public Const VersionCode As Integer = 377 'Snapshot
|
Public Const VersionCode As Integer = 378 'Snapshot
|
||||||
#End If
|
#End If
|
||||||
'自动生成的版本信息
|
'自动生成的版本信息
|
||||||
Public Const VersionDisplayName As String = VersionBranchName & " " & VersionBaseName
|
Public Const VersionDisplayName As String = VersionBranchName & " " & VersionBaseName
|
||||||
@@ -589,8 +589,7 @@ Public Module ModBase
|
|||||||
''' </summary>
|
''' </summary>
|
||||||
Public Function ReadReg(Key As String, Optional DefaultValue As String = "") As String
|
Public Function ReadReg(Key As String, Optional DefaultValue As String = "") As String
|
||||||
Try
|
Try
|
||||||
Dim SubKey = My.Computer.Registry.CurrentUser.OpenSubKey("Software\" & RegFolder, False)
|
Return If(My.Computer.Registry.CurrentUser.OpenSubKey("Software\" & RegFolder, False)?.GetValue(Key), DefaultValue)
|
||||||
Return If(SubKey?.GetValue(Key), DefaultValue)
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
Log(ex, "读取注册表出错:" & Key, LogLevel.Hint)
|
Log(ex, "读取注册表出错:" & Key, LogLevel.Hint)
|
||||||
Return DefaultValue
|
Return DefaultValue
|
||||||
|
|||||||
@@ -561,7 +561,7 @@
|
|||||||
Dim EndName = McVersion.DropToVersion(EndDrop)
|
Dim EndName = McVersion.DropToVersion(EndDrop)
|
||||||
If StartDrop = EndDrop Then
|
If StartDrop = EndDrop Then
|
||||||
Segments.Add(StartName)
|
Segments.Add(StartName)
|
||||||
ElseIf AllDrops?.Any AndAlso StartDrop >= AllDrops.First Then
|
ElseIf AllDrops IsNot Nothing AndAlso StartDrop >= AllDrops.First Then
|
||||||
If EndDrop < 100 Then
|
If EndDrop < 100 Then
|
||||||
Segments.Clear()
|
Segments.Clear()
|
||||||
Segments.Add("全版本")
|
Segments.Add("全版本")
|
||||||
|
|||||||
@@ -152,14 +152,16 @@
|
|||||||
#Region "DlClientList | Minecraft 客户端 版本列表"
|
#Region "DlClientList | Minecraft 客户端 版本列表"
|
||||||
|
|
||||||
''' <summary>
|
''' <summary>
|
||||||
''' 所有正式版的 Minecraft Drop 序数,按从高到低排列。
|
''' 所有正式版的 Minecraft Drop 序数。
|
||||||
''' Nothing 代表从未完成过获取。
|
''' 若从未完成过获取,返回 Nothing;否则必定存在元素,且从高到低排列。
|
||||||
''' </summary>
|
''' </summary>
|
||||||
Public Property AllDrops As List(Of Integer)
|
Public Property AllDrops As List(Of Integer)
|
||||||
Get
|
Get
|
||||||
If _AllDrops Is Nothing Then _AllDrops = Setup.Get("CacheDrops").ToString.Split(","c).Select(Function(d) CInt(d)).ToList()
|
If _AllDrops Is Nothing Then
|
||||||
If Not _AllDrops.Any Then _AllDrops = Nothing
|
_AllDrops = Setup.Get("CacheDrops").ToString.
|
||||||
Return _AllDrops
|
Split(",".ToCharArray, StringSplitOptions.RemoveEmptyEntries).Select(Function(d) CInt(Val(d))).ToList()
|
||||||
|
End If
|
||||||
|
Return If(_AllDrops.Any, _AllDrops, Nothing) '不要将 _AllDrops 再设为 Nothing,以防止反复获取设置尝试初始化
|
||||||
End Get
|
End Get
|
||||||
Set(value As List(Of Integer))
|
Set(value As List(Of Integer))
|
||||||
_AllDrops = value
|
_AllDrops = value
|
||||||
|
|||||||
@@ -730,7 +730,7 @@ Wait:
|
|||||||
TargetEntry = Components.Property(Loader.Input)
|
TargetEntry = Components.Property(Loader.Input)
|
||||||
Else '模糊匹配
|
Else '模糊匹配
|
||||||
TargetEntry = Components.Properties.FirstOrDefault(
|
TargetEntry = Components.Properties.FirstOrDefault(
|
||||||
Function(c) c.Value?.ToArray.FirstOrDefault()?("version")("name").ToString.StartsWithF(Loader.Input))
|
Function(c) c.Value IsNot Nothing AndAlso c.Value.ToArray.FirstOrDefault()?("version")("name").ToString.StartsWithF(Loader.Input))
|
||||||
If TargetEntry Is Nothing Then Throw New Exception($"未能找到所需的 Java {Loader.Input}")
|
If TargetEntry Is Nothing Then Throw New Exception($"未能找到所需的 Java {Loader.Input}")
|
||||||
End If
|
End If
|
||||||
Dim TargetComponent = TargetEntry.Value.ToArray.FirstOrDefault
|
Dim TargetComponent = TargetEntry.Value.ToArray.FirstOrDefault
|
||||||
|
|||||||
@@ -158,7 +158,7 @@ Public Module ModMinecraft
|
|||||||
|
|
||||||
#Region "版本处理"
|
#Region "版本处理"
|
||||||
|
|
||||||
Public Const McInstanceCacheVersion As Integer = 32
|
Public Const McInstanceCacheVersion As Integer = 33
|
||||||
|
|
||||||
Private _McInstanceSelected As McInstance
|
Private _McInstanceSelected As McInstance
|
||||||
''' <summary>
|
''' <summary>
|
||||||
@@ -1013,10 +1013,10 @@ ExitDataLoad:
|
|||||||
'字母编号,如 G2 中的 G(7)
|
'字母编号,如 G2 中的 G(7)
|
||||||
Dim Result As Integer = Asc(OptiFine.ToUpper.First) - Asc("A"c) + 1
|
Dim Result As Integer = Asc(OptiFine.ToUpper.First) - Asc("A"c) + 1
|
||||||
'末尾数字,如 C5 beta4 中的 5
|
'末尾数字,如 C5 beta4 中的 5
|
||||||
Result *= Result * 100
|
Result *= 100
|
||||||
Result += Val(RegexSeek(Right(OptiFine, OptiFine.Length - 1), "[0-9]+"))
|
Result += Val(RegexSeek(Right(OptiFine, OptiFine.Length - 1), "[0-9]+"))
|
||||||
'测试标记(正式版为 99,Pre[x] 为 50+x,Beta[x] 为 x)
|
'测试标记(正式版为 99,Pre[x] 为 50+x,Beta[x] 为 x)
|
||||||
Result *= Result * 100
|
Result *= 100
|
||||||
If OptiFine.ContainsF("pre", True) Then Result += 50
|
If OptiFine.ContainsF("pre", True) Then Result += 50
|
||||||
If OptiFine.ContainsF("pre", True) OrElse OptiFine.ContainsF("beta", True) Then
|
If OptiFine.ContainsF("pre", True) OrElse OptiFine.ContainsF("beta", True) Then
|
||||||
If Val(Right(OptiFine, 1)) = 0 AndAlso Right(OptiFine, 1) <> "0" Then
|
If Val(Right(OptiFine, 1)) = 0 AndAlso Right(OptiFine, 1) <> "0" Then
|
||||||
|
|||||||
@@ -115,7 +115,7 @@ Public Module ModMod
|
|||||||
End Get
|
End Get
|
||||||
Set(value As String)
|
Set(value As String)
|
||||||
If _Version IsNot Nothing AndAlso RegexCheck(_Version, "[0-9.\-]+") Then Return
|
If _Version IsNot Nothing AndAlso RegexCheck(_Version, "[0-9.\-]+") Then Return
|
||||||
If value?.ContainsF("version", True) Then value = "version" '需要修改的标识
|
If value IsNot Nothing AndAlso value.ContainsF("version", True) Then value = "version" '需要修改的标识
|
||||||
_Version = value
|
_Version = value
|
||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|||||||
@@ -278,7 +278,7 @@ Retry:
|
|||||||
If ModJson("modules").Any Then 'modules 可能返回 null(#1006)
|
If ModJson("modules").Any Then 'modules 可能返回 null(#1006)
|
||||||
Dim ModuleNames = CType(ModJson("modules"), JArray).Select(Function(l) l("name").ToString).ToList
|
Dim ModuleNames = CType(ModJson("modules"), JArray).Select(Function(l) l("name").ToString).ToList
|
||||||
If ModuleNames.Contains("META-INF") OrElse ModuleNames.Contains("mcmod.info") OrElse
|
If ModuleNames.Contains("META-INF") OrElse ModuleNames.Contains("mcmod.info") OrElse
|
||||||
ModJson?("FileName")?.ToString?.EndsWithF(".jar", True) Then
|
ModJson?("FileName")?.ToString.EndsWithF(".jar", True) Then
|
||||||
TargetFolder = "mods" : Type = CompType.Mod
|
TargetFolder = "mods" : Type = CompType.Mod
|
||||||
ElseIf ModuleNames.Contains("pack.mcmeta") Then
|
ElseIf ModuleNames.Contains("pack.mcmeta") Then
|
||||||
TargetFolder = "resourcepacks" : Type = CompType.ResourcePack
|
TargetFolder = "resourcepacks" : Type = CompType.ResourcePack
|
||||||
|
|||||||
@@ -175,10 +175,10 @@ Public Class CustomEvent
|
|||||||
Public Shared Sub Raise(Type As EventType, Arg As String)
|
Public Shared Sub Raise(Type As EventType, Arg As String)
|
||||||
If Type = EventType.None Then Return
|
If Type = EventType.None Then Return
|
||||||
Log($"[Control] 执行自定义事件:{Type}, {Arg}")
|
Log($"[Control] 执行自定义事件:{Type}, {Arg}")
|
||||||
|
If Arg Is Nothing Then Arg = ""
|
||||||
|
Dim Args As String() = Arg.Split("|")
|
||||||
Try
|
Try
|
||||||
Dim Args As String() = If(Arg?.Split("|"), {""})
|
|
||||||
Select Case Type
|
Select Case Type
|
||||||
|
|
||||||
Case EventType.打开网页
|
Case EventType.打开网页
|
||||||
Arg = Arg.Replace("\", "/")
|
Arg = Arg.Replace("\", "/")
|
||||||
If Not Arg.Contains("://") OrElse Arg.StartsWithF("file", True) Then '为了支持更多协议(#2200)
|
If Not Arg.Contains("://") OrElse Arg.StartsWithF("file", True) Then '为了支持更多协议(#2200)
|
||||||
|
|||||||
@@ -792,8 +792,7 @@ NextFile:
|
|||||||
'查看现有设置
|
'查看现有设置
|
||||||
Using ReadOnlyKey = My.Computer.Registry.CurrentUser.OpenSubKey(REG_KEY, False)
|
Using ReadOnlyKey = My.Computer.Registry.CurrentUser.OpenSubKey(REG_KEY, False)
|
||||||
If ReadOnlyKey IsNot Nothing Then
|
If ReadOnlyKey IsNot Nothing Then
|
||||||
Dim CurrentValue = ReadOnlyKey.GetValue(Executeable)
|
If REG_VALUE = ReadOnlyKey.GetValue(Executeable)?.ToString() Then
|
||||||
If REG_VALUE = CurrentValue?.ToString() Then
|
|
||||||
Log($"[System] 无需调整显卡设置:{Executeable}")
|
Log($"[System] 无需调整显卡设置:{Executeable}")
|
||||||
Return
|
Return
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -261,6 +261,7 @@
|
|||||||
|
|
||||||
''' <summary>
|
''' <summary>
|
||||||
''' 当前正在播放的 NAudio.Wave.WaveOutEvent。
|
''' 当前正在播放的 NAudio.Wave.WaveOutEvent。
|
||||||
|
''' 如果为它赋了类别,则会没有必要地加载 NAudio.dll。
|
||||||
''' </summary>
|
''' </summary>
|
||||||
Public MusicNAudio = Nothing
|
Public MusicNAudio = Nothing
|
||||||
''' <summary>
|
''' <summary>
|
||||||
|
|||||||
@@ -51,6 +51,6 @@ Imports System.Runtime.InteropServices
|
|||||||
' 可以指定所有值,也可以使用以下所示的 "*" 预置版本号和修订号
|
' 可以指定所有值,也可以使用以下所示的 "*" 预置版本号和修订号
|
||||||
' 方法是按如下所示使用“*”
|
' 方法是按如下所示使用“*”
|
||||||
|
|
||||||
<Assembly: AssemblyVersion("2.12.0.0")>
|
<Assembly: AssemblyVersion("2.12.1.0")>
|
||||||
<Assembly: AssemblyFileVersion("2.12.0.0")>
|
<Assembly: AssemblyFileVersion("2.12.1.0")>
|
||||||
<Assembly: NeutralResourcesLanguage("")>
|
<Assembly: NeutralResourcesLanguage("")>
|
||||||
|
|||||||
@@ -111,7 +111,7 @@ Public Class PageComp
|
|||||||
IsFirstLoaded = True
|
IsFirstLoaded = True
|
||||||
CType(Parent, MyPageRight).PageLoaderInit(Load, PanLoad, PanContent, PanAlways, Loader, AddressOf Load_OnFinish, AddressOf LoaderInput)
|
CType(Parent, MyPageRight).PageLoaderInit(Load, PanLoad, PanContent, PanAlways, Loader, AddressOf Load_OnFinish, AddressOf LoaderInput)
|
||||||
'将最高 Drop 加入筛选
|
'将最高 Drop 加入筛选
|
||||||
If AllDrops?.Any AndAlso AllDrops.First > 250 Then
|
If AllDrops IsNot Nothing AndAlso AllDrops.First > 250 Then
|
||||||
Dim HighestVersion As String = McVersion.DropToVersion(AllDrops.First)
|
Dim HighestVersion As String = McVersion.DropToVersion(AllDrops.First)
|
||||||
If CType(TextSearchVersion.Items(1), MyComboBoxItem).Content.ToString <> HighestVersion Then '0 是全部
|
If CType(TextSearchVersion.Items(1), MyComboBoxItem).Content.ToString <> HighestVersion Then '0 是全部
|
||||||
TextSearchVersion.Items.Insert(1, New MyComboBoxItem With {.Content = HighestVersion})
|
TextSearchVersion.Items.Insert(1, New MyComboBoxItem With {.Content = HighestVersion})
|
||||||
|
|||||||
Reference in New Issue
Block a user