diff --git a/src/MeoAsstGui/Helper/AsstProxy.cs b/src/MeoAsstGui/Helper/AsstProxy.cs index a053000e68..ef22532b88 100644 --- a/src/MeoAsstGui/Helper/AsstProxy.cs +++ b/src/MeoAsstGui/Helper/AsstProxy.cs @@ -447,6 +447,11 @@ namespace MeoAsstGui break; case AsstMsg.TaskChainCompleted: + if (taskChain == "Infrast") + { + mainModel.IncreaseCustomInfrastPlanIndex(); + } + mainModel.AddLog(Localization.GetString("CompleteTask") + taskChain); if (taskChain == "Copilot") { diff --git a/src/MeoAsstGui/Resources/Localizations/zh-cn.xaml b/src/MeoAsstGui/Resources/Localizations/zh-cn.xaml index 2de5ab30d2..b69f0577a0 100644 --- a/src/MeoAsstGui/Resources/Localizations/zh-cn.xaml +++ b/src/MeoAsstGui/Resources/Localizations/zh-cn.xaml @@ -43,6 +43,7 @@ 自定义基建配置文件解析错误! 自定义基建配置: 基建计划 + 自动保存为下个计划 通用模式 蓝叠模拟器 diff --git a/src/MeoAsstGui/ViewModels/TaskQueueViewModel.cs b/src/MeoAsstGui/ViewModels/TaskQueueViewModel.cs index 592a74c8b3..aa3a5a13ce 100644 --- a/src/MeoAsstGui/ViewModels/TaskQueueViewModel.cs +++ b/src/MeoAsstGui/ViewModels/TaskQueueViewModel.cs @@ -1535,6 +1535,24 @@ namespace MeoAsstGui } } + public void IncreaseCustomInfrastPlanIndex() + { + if (!CustomInfrastEnabled) + { + return; + } + + AddLog(Localization.GetString("CustomInfrastPlanIndexAutoSwitch"), LogColor.Message); + if (CustomInfrastPlanIndex >= CustomInfrastPlanList.Count - 1) + { + CustomInfrastPlanIndex = 0; + } + else + { + ++CustomInfrastPlanIndex; + } + } + public ObservableCollection> CustomInfrastPlanList { get; set; } = new ObservableCollection>(); public struct CustomInfrastPlanInfo