修复多开出现多余默认存档的问题

Fix #279
This commit is contained in:
ZouJin 2023-11-07 18:52:10 +08:00
parent 80228c99cf
commit f5a0341020
2 changed files with 1 additions and 5 deletions

View File

@ -1009,7 +1009,7 @@ namespace VPet_Simulator.Windows
public MainWindow(string prefixsave)
{
PrefixSave = prefixsave;
if (!PrefixSave.StartsWith("-"))
if (prefixsave != string.Empty && !PrefixSave.StartsWith("-"))
PrefixSave = '-' + prefixsave;
//处理ARGS
Args = new LPS_D();

View File

@ -1457,10 +1457,6 @@ namespace VPet_Simulator.Windows
if (LBHave.SelectedIndex == -1)
return;
var str = App.MutiSaves[LBHave.SelectedIndex];
if (str == "默认存档".Translate())
{
str = string.Empty;
}
if (str.EndsWith(")") || App.MainWindows.FirstOrDefault(x => x.PrefixSave.Trim('-') == str) != null)
{
MessageBoxX.Show("当前多开已经加载".Translate());