From ae0be8a9a930bd40e9f90ee0e66fa195ad42f5d4 Mon Sep 17 00:00:00 2001
From: lpowo <113409320+lpowo@users.noreply.github.com>
Date: Wed, 13 Dec 2023 16:22:59 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E5=A2=9E=E5=8A=A0=E5=85=AC=E6=8B=9B?=
=?UTF-8?q?=E5=A4=9A=E9=80=89=E7=AD=96=E7=95=A5=20(#7463)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* fix #7452
按照 #7452 的想法,在 #6900 的基础上增加了只选尽可能多选且只选高星tag的功能选项,并将选项策略合并
默认策略:只选一个高星tag组合
#6900 策略:选满三个tag为止
新增策略:尽可能多选高星tag,且额外的tag组合要么完整选入,要么舍弃;且若当前出现更高星tag组合,则不会考虑较低星,只会尽可能选高星tag组合(例如出现五星tag时,将尽力多选五星tag,不会考虑四星tag)
(result_vec的排序规则暂时未更改)
在GUI中增加了选择公招策略的功能,如图:


最后用模拟器在自己账号上进行了一些自动公招测试。
---------
Co-authored-by: David <56174894+Constrat@users.noreply.github.com>
Co-authored-by: Horror Proton <107091537+horror-proton@users.noreply.github.com>
---
docs/en-us/3.1-INTEGRATION.md | 4 ++
docs/ja-jp/3.1-統合ドキュメント.md | 1 +
docs/ko-kr/3.1-연동.md | 1 +
docs/zh-tw/3.1-集成文件.md | 6 ++-
docs/协议文档/集成文档.md | 4 ++
.../Config/Miscellaneous/RecruitConfig.h | 14 ++++++
src/MaaCore/Task/Interface/RecruitTask.cpp | 9 +++-
.../Task/Miscellaneous/AutoRecruitTask.cpp | 43 ++++++++++++++++---
.../Task/Miscellaneous/AutoRecruitTask.h | 4 +-
src/MaaWpfGui/Main/AsstProxy.cs | 22 ++++++++--
src/MaaWpfGui/Res/Localizations/en-us.xaml | 3 ++
src/MaaWpfGui/Res/Localizations/ja-jp.xaml | 3 ++
src/MaaWpfGui/Res/Localizations/ko-kr.xaml | 3 ++
src/MaaWpfGui/Res/Localizations/zh-cn.xaml | 3 ++
src/MaaWpfGui/Res/Localizations/zh-tw.xaml | 3 ++
.../ViewModels/UI/SettingsViewModel.cs | 43 ++++++++++++++++---
.../ViewModels/UI/TaskQueueViewModel.cs | 4 +-
.../AutoRecruitSettingsUserControl.xaml | 14 +++---
18 files changed, 158 insertions(+), 26 deletions(-)
diff --git a/docs/en-us/3.1-INTEGRATION.md b/docs/en-us/3.1-INTEGRATION.md
index 3d415a3dae..c9f597daf4 100644
--- a/docs/en-us/3.1-INTEGRATION.md
+++ b/docs/en-us/3.1-INTEGRATION.md
@@ -105,6 +105,10 @@ Supports some of the special stages,Please refer to [autoLocalization example](.
int,
...
],
+ "extra_tags_mode": int, // Select more tags, optional
+ // 0 - default
+ // 1 - click 3 tags anyway, even if they are in conflict
+ // 2 - select more combinations if possible, even if their tags are in conflict
"times": int, // The times of recruitment, optional, by default 0. Can be set to 0 for calculation only.
"set_time": bool, // Whether to set time to 9 hours, available only when `times` is 0, optional, by default true
"expedite": bool, // Whether to use expedited plans, optional, by default false
diff --git a/docs/ja-jp/3.1-統合ドキュメント.md b/docs/ja-jp/3.1-統合ドキュメント.md
index 888d4de2b2..46758981af 100644
--- a/docs/ja-jp/3.1-統合ドキュメント.md
+++ b/docs/ja-jp/3.1-統合ドキュメント.md
@@ -97,6 +97,7 @@ TaskId ASSTAPI AsstAppendTask(AsstHandle handle, const char* type, const char* p
int,
...
],
+ "extra_tags_mode": int,
"times": int, // 採用回数, オプション, デフォルトは 0. 0 にセットすることで計算だけに使用可能.
"set_time": bool, // 時刻を9時間に設定するかどうか, `times` が 0 の時のみ設定可能, オプション, デフォルトは true
"expedite": bool, // 緊急招集票の使用, オプション, デフォルトは false
diff --git a/docs/ko-kr/3.1-연동.md b/docs/ko-kr/3.1-연동.md
index 426020ecb9..283b12b218 100644
--- a/docs/ko-kr/3.1-연동.md
+++ b/docs/ko-kr/3.1-연동.md
@@ -104,6 +104,7 @@ TaskId ASSTAPI AsstAppendTask(AsstHandle handle, const char* type, const char* p
int,
...
],
+ "extra_tags_mode": int,
"times": int, // 고용 횟수, 선택 사항, 기본값은 0입니다. 계산용으로만 0으로 설정할 수 있습니다.
"set_time": bool, // 시간을 9시간으로 설정할지 여부, `times`가 0인 경우에만 사용 가능한 옵션입니다, 선택 사항, 기본값은 true입니다.
"expedite": bool, // 즉시 완료 허가증을 사용할지 여부, 선택 사항, 기본값은 false입니다.
diff --git a/docs/zh-tw/3.1-集成文件.md b/docs/zh-tw/3.1-集成文件.md
index dc48d6d1ce..4d9ce2cf50 100644
--- a/docs/zh-tw/3.1-集成文件.md
+++ b/docs/zh-tw/3.1-集成文件.md
@@ -112,6 +112,10 @@ AsstTaskId ASSTAPI AsstAppendTask(AsstHandle handle, const char* type, const cha
int,
...
],
+ "extra_tags_mode": int, // 選擇更多的 Tags, 可選, 預設為 0
+ // 0 - 預設行為
+ // 1 - 選 3 個 Tags, 即使可能衝突
+ // 2 - 如果可能, 同時選擇更多的高星 Tag 組合, 即使可能衝突
"times": int, // 招募多少次,可選,預設 0。若僅公招計算,可設定為 0
"set_time": bool, // 是否設定招募時限。僅在 times 為 0 時生效,可選,預設 true
"expedite": bool, // 是否使用加急許可,可選,預設 false
@@ -422,4 +426,4 @@ bool ASSTAPI AsstSetInstanceOption(AsstHandle handle, AsstInstanceOptionKey key,
AdbLiteEnabled = 4, // 是否使用 AdbLite,"0" | "1"
KillAdbOnExit = 5, // 退出時是否殺掉 Adb,"0" | "1"
};
-```
\ No newline at end of file
+```
diff --git a/docs/协议文档/集成文档.md b/docs/协议文档/集成文档.md
index 577f4efca7..56d0edb329 100644
--- a/docs/协议文档/集成文档.md
+++ b/docs/协议文档/集成文档.md
@@ -114,6 +114,10 @@ AsstTaskId ASSTAPI AsstAppendTask(AsstHandle handle, const char* type, const cha
int,
...
],
+ "extra_tags_mode": int, // 选择更多的 Tags, 可选, 默认为 0
+ // 0 - 默认行为
+ // 1 - 选 3 个 Tags, 即使可能冲突
+ // 2 - 如果可能, 同时选择更多的高星 Tag 组合, 即使可能冲突
"times": int, // 招募多少次,可选,默认 0。若仅公招计算,可设置为 0
"set_time": bool, // 是否设置招募时限。仅在 times 为 0 时生效,可选,默认 true
"expedite": bool, // 是否使用加急许可,可选,默认 false
diff --git a/src/MaaCore/Config/Miscellaneous/RecruitConfig.h b/src/MaaCore/Config/Miscellaneous/RecruitConfig.h
index df0392696f..88dc6d9f0c 100644
--- a/src/MaaCore/Config/Miscellaneous/RecruitConfig.h
+++ b/src/MaaCore/Config/Miscellaneous/RecruitConfig.h
@@ -89,10 +89,24 @@ namespace asst
}
};
+ // 选择额外 Tags 的模式
+ enum class ExtraTagsMode
+ {
+ NoExtra, // 0 - 默认行为
+ Extra, // 1 - 选 3 个 Tags, 即使可能冲突
+ ExtraOnlyRare, // 2 - 如果可能, 同时选择更多的高星 Tag 组合, 即使可能冲突
+ };
+
class RecruitConfig final : public SingletonHolder, public AbstractConfig
{
public:
using TagId = std::string;
+
+ public:
+ static constexpr bool is_valid_extra_tags_mode(ExtraTagsMode mode)
+ {
+ return mode == ExtraTagsMode::NoExtra || mode == ExtraTagsMode::Extra || mode == ExtraTagsMode::ExtraOnlyRare;
+ }
public:
virtual ~RecruitConfig() override = default;
diff --git a/src/MaaCore/Task/Interface/RecruitTask.cpp b/src/MaaCore/Task/Interface/RecruitTask.cpp
index 1e8c125546..8740c3d6f7 100644
--- a/src/MaaCore/Task/Interface/RecruitTask.cpp
+++ b/src/MaaCore/Task/Interface/RecruitTask.cpp
@@ -39,12 +39,17 @@ bool asst::RecruitTask::set_params(const json::value& params)
confirm.emplace_back(confirm_num_json.as_integer());
}
+ ExtraTagsMode extra_tags_mode = static_cast(params.get("extra_tags_mode", 0));
+ // 若出现未知 extra_tags_mode , 将 extra_tags_mod 置为默认的 NoExtra 。
+ if (!RecruitConfig::is_valid_extra_tags_mode(extra_tags_mode)) {
+ extra_tags_mode = ExtraTagsMode::NoExtra;
+ }
+
bool refresh = params.get("refresh", false);
bool set_time = params.get("set_time", true);
bool force_refresh = params.get("force_refresh", true);
int times = params.get("times", 0);
bool expedite = params.get("expedite", false);
- bool extra_tags = params.get("extra_tags", false);
[[maybe_unused]] int expedite_times = params.get("expedite_times", 0);
bool skip_robot = params.get("skip_robot", true);
@@ -65,7 +70,7 @@ bool asst::RecruitTask::set_params(const json::value& params)
m_auto_recruit_task_ptr->set_max_times(times)
.set_need_refresh(refresh)
.set_use_expedited(expedite)
- .set_select_extra_tags(extra_tags)
+ .set_select_extra_tags(extra_tags_mode)
.set_select_level(std::move(select))
.set_confirm_level(std::move(confirm))
.set_skip_robot(skip_robot)
diff --git a/src/MaaCore/Task/Miscellaneous/AutoRecruitTask.cpp b/src/MaaCore/Task/Miscellaneous/AutoRecruitTask.cpp
index b108753711..f525836694 100644
--- a/src/MaaCore/Task/Miscellaneous/AutoRecruitTask.cpp
+++ b/src/MaaCore/Task/Miscellaneous/AutoRecruitTask.cpp
@@ -140,9 +140,9 @@ asst::AutoRecruitTask& asst::AutoRecruitTask::set_use_expedited(bool use_or_not)
return *this;
}
-asst::AutoRecruitTask& asst::AutoRecruitTask::set_select_extra_tags(bool select_extra_tags) noexcept
+asst::AutoRecruitTask& asst::AutoRecruitTask::set_select_extra_tags(ExtraTagsMode select_extra_tags_mode) noexcept
{
- m_select_extra_tags = select_extra_tags;
+ m_select_extra_tags_mode = select_extra_tags_mode;
return *this;
}
@@ -578,7 +578,8 @@ asst::AutoRecruitTask::calc_task_result_type asst::AutoRecruitTask::recruit_calc
return result;
}
- auto final_select = m_select_extra_tags ? get_select_tags(result_vec) : final_combination.tags;
+ auto final_select =
+ (m_select_extra_tags_mode != ExtraTagsMode::NoExtra) ? get_select_tags(result_vec) : final_combination.tags;
// select tags
for (const std::string& final_tag_name : final_select) {
@@ -707,21 +708,49 @@ std::vector asst::AutoRecruitTask::get_tag_names(const std::vector<
return names;
}
-std::vector asst::AutoRecruitTask::get_select_tags(const std::vector& conbinations)
+std::vector asst::AutoRecruitTask::get_select_tags(const std::vector& combinations)
{
LogTraceFunction;
std::unordered_set unique_tags;
std::vector select;
- while (select.size() < 3) {
- for (const asst::RecruitCombs& comb : conbinations)
+ if (m_select_extra_tags_mode == ExtraTagsMode::Extra) {
+ while (select.size() < 3) {
+ for (const asst::RecruitCombs& comb : combinations)
+ for (const std::string& tag : comb.tags) {
+ if (unique_tags.find(tag) == unique_tags.cend()) {
+ unique_tags.insert(tag);
+ select.emplace_back(tag);
+ if (select.size() == 3) return select;
+ }
+ }
+ }
+ }
+ else if (m_select_extra_tags_mode == ExtraTagsMode::ExtraOnlyRare) {
+ // only select rare tags ( > 3 rank) and select as many as possible.
+
+ // do not select lower rank tags when higher rank tags exist.
+ int min_level = combinations.front().min_level;
+ // tag combo will be either full selected, or abandoned.
+ int emplace_back_count = 0;
+ if (min_level == 3) return select;
+ for (const asst::RecruitCombs& comb : combinations) {
+ if (comb.min_level < min_level) return select;
+ emplace_back_count = 0;
for (const std::string& tag : comb.tags) {
if (unique_tags.find(tag) == unique_tags.cend()) {
unique_tags.insert(tag);
select.emplace_back(tag);
- if (select.size() == 3) return select;
+ ++emplace_back_count;
}
}
+ if (select.size() > 3) {
+ while (emplace_back_count--) {
+ unique_tags.erase(select.back());
+ select.pop_back();
+ }
+ }
+ }
}
return select;
}
diff --git a/src/MaaCore/Task/Miscellaneous/AutoRecruitTask.h b/src/MaaCore/Task/Miscellaneous/AutoRecruitTask.h
index 43a9089da7..867e2ce31b 100644
--- a/src/MaaCore/Task/Miscellaneous/AutoRecruitTask.h
+++ b/src/MaaCore/Task/Miscellaneous/AutoRecruitTask.h
@@ -23,7 +23,7 @@ namespace asst
AutoRecruitTask& set_need_refresh(bool need_refresh) noexcept;
AutoRecruitTask& set_max_times(int max_times) noexcept;
AutoRecruitTask& set_use_expedited(bool use_or_not) noexcept;
- AutoRecruitTask& set_select_extra_tags(bool select_extra_tags) noexcept;
+ AutoRecruitTask& set_select_extra_tags(ExtraTagsMode select_extra_tags_mode) noexcept;
AutoRecruitTask& set_skip_robot(bool skip_robot) noexcept;
AutoRecruitTask& set_set_time(bool set_time) noexcept;
AutoRecruitTask& set_force_refresh(bool force_refrest) noexcept;
@@ -76,7 +76,7 @@ namespace asst
std::vector m_confirm_level;
bool m_need_refresh = false;
bool m_use_expedited = false;
- bool m_select_extra_tags = false;
+ ExtraTagsMode m_select_extra_tags_mode = ExtraTagsMode::NoExtra;
int m_max_times = 0;
bool m_has_permit = true;
bool m_has_refresh = true;
diff --git a/src/MaaWpfGui/Main/AsstProxy.cs b/src/MaaWpfGui/Main/AsstProxy.cs
index 8155cd911c..702db74a98 100644
--- a/src/MaaWpfGui/Main/AsstProxy.cs
+++ b/src/MaaWpfGui/Main/AsstProxy.cs
@@ -1766,13 +1766,29 @@ namespace MaaWpfGui.Main
/// 是否刷新三星 Tags。
/// 无招募许可时是否继续尝试刷新 Tags。
/// 是否使用加急许可。
- /// 选择 Tags 时是否总是选择三个 Tag
+ ///
+ /// 公招选择额外tag的模式。可用值包括:
+ ///
+ /// -
+ /// 0
+ /// 默认不选择额外tag。
+ ///
+ /// -
+ /// 1
+ /// 选满至3个tag。
+ ///
+ /// -
+ /// 2
+ /// 尽可能多选且只选四星以上的tag。
+ ///
+ ///
+ ///
/// 是否在识别到小车词条时跳过。
/// 三星Tag是否使用短时间(7:40)
/// 三星Tag是否使用短时间(1:00)
/// 是否成功。
public bool AsstAppendRecruit(int maxTimes, int[] selectLevel, int[] confirmLevel, bool needRefresh, bool needForceRefresh, bool useExpedited,
- bool selectExtraTags, bool skipRobot, bool isLevel3UseShortTime, bool isLevel3UseShortTime2 = false)
+ int selectExtraTagsMode, bool skipRobot, bool isLevel3UseShortTime, bool isLevel3UseShortTime2 = false)
{
var taskParams = new JObject
{
@@ -1783,7 +1799,7 @@ namespace MaaWpfGui.Main
["times"] = maxTimes,
["set_time"] = true,
["expedite"] = useExpedited,
- ["extra_tags"] = selectExtraTags,
+ ["extra_tags_mode"] = selectExtraTagsMode,
["expedite_times"] = maxTimes,
["skip_robot"] = skipRobot,
};
diff --git a/src/MaaWpfGui/Res/Localizations/en-us.xaml b/src/MaaWpfGui/Res/Localizations/en-us.xaml
index 1e03124571..212ae3357d 100644
--- a/src/MaaWpfGui/Res/Localizations/en-us.xaml
+++ b/src/MaaWpfGui/Res/Localizations/en-us.xaml
@@ -634,7 +634,10 @@ The video aspect ratio needs to be 16:9 without interference factors such as bla
Refreshed
No recruitment permit, trying to refresh Tags
No recruitment permit, returned
+ Strategies for Additional Tags
+ Additional Tags are not selected by default
When selecting Tags always select three Tags
+ Pick as many high-star Tags as possible
Insufficient operators
Stage recognition error
Use formation
diff --git a/src/MaaWpfGui/Res/Localizations/ja-jp.xaml b/src/MaaWpfGui/Res/Localizations/ja-jp.xaml
index 030ceed717..2ffcca9097 100644
--- a/src/MaaWpfGui/Res/Localizations/ja-jp.xaml
+++ b/src/MaaWpfGui/Res/Localizations/ja-jp.xaml
@@ -634,7 +634,10 @@ Bilibili: ログイン インターフェイスに表示されるアカウント
現在のタグが更新されました
採用許可がないため、タグを更新しようとしています
採用許可がないため返却されました
+ 公募の複数のタグを選択する戦略
+ デフォルトでは、追加のタグを選択しない
タグを選択すると、常に 3 つのタグが選択されます
+ 可能な限り多くのタグを選択し、高い星のタグのみを選択する
利用可能なオペレーターが不足しています
ステージ認識エラー
使用編成
diff --git a/src/MaaWpfGui/Res/Localizations/ko-kr.xaml b/src/MaaWpfGui/Res/Localizations/ko-kr.xaml
index aadc686c6e..977da6bfae 100644
--- a/src/MaaWpfGui/Res/Localizations/ko-kr.xaml
+++ b/src/MaaWpfGui/Res/Localizations/ko-kr.xaml
@@ -634,7 +634,10 @@ Bilibili: 로그인 인터페이스에 표시되는 계정 이름(예: 장산)
새로고침됨
채용 허가 없음, 새로 고치려고 태그
채용허가증이 없어 반환함
+ 공개 채용에서 다중 태그 선택 전략
+ 기본값:추가 태그 없습니다
태그를 선택할 때 항상 태그 3개를 선택하세요.
+ 가능한 한 많은 태그를 선택하고 높은 등급의 태그만 선택합니다
오퍼레이터 부족
스테이지 인식 오류
사용 형성
diff --git a/src/MaaWpfGui/Res/Localizations/zh-cn.xaml b/src/MaaWpfGui/Res/Localizations/zh-cn.xaml
index 03a171e94e..237a808287 100644
--- a/src/MaaWpfGui/Res/Localizations/zh-cn.xaml
+++ b/src/MaaWpfGui/Res/Localizations/zh-cn.xaml
@@ -634,7 +634,10 @@
当前槽位已刷新
无招聘许可,继续尝试刷新 Tags
无招聘许可,已返回
+ 公招多选 Tag 的策略
+ 默认不选择额外 Tag
总是选择三个 Tag
+ 尽可能多地选且只选高星 Tag
可用干员不足
关卡识别错误
使用编队
diff --git a/src/MaaWpfGui/Res/Localizations/zh-tw.xaml b/src/MaaWpfGui/Res/Localizations/zh-tw.xaml
index e1811bd136..7010c5ecbc 100644
--- a/src/MaaWpfGui/Res/Localizations/zh-tw.xaml
+++ b/src/MaaWpfGui/Res/Localizations/zh-tw.xaml
@@ -635,7 +635,10 @@
無招聘許可,繼續嘗試刷新 Tags
無招聘許可,已返回
可用幹員不足
+ 公招多選 Tags 的策略
+ 默認不選擇額外的 Tags
選擇 Tags 時總是選擇三個 Tag
+ 盡可能多地選且只選高星 Tags
關卡辨識錯誤
使用編隊
當前
diff --git a/src/MaaWpfGui/ViewModels/UI/SettingsViewModel.cs b/src/MaaWpfGui/ViewModels/UI/SettingsViewModel.cs
index 4754c4fd05..0b682ecd44 100644
--- a/src/MaaWpfGui/ViewModels/UI/SettingsViewModel.cs
+++ b/src/MaaWpfGui/ViewModels/UI/SettingsViewModel.cs
@@ -169,6 +169,7 @@ namespace MaaWpfGui.ViewModels.UI
InitTitleBar();
InitInfrast();
InitRoguelike();
+ InitAutoRecruit();
InitConfiguration();
InitUiSettings();
InitUpdate();
@@ -280,6 +281,16 @@ namespace MaaWpfGui.ViewModels.UI
};
}
+ private void InitAutoRecruit()
+ {
+ AutoRecruitSelectExtraTagsList = new List
+ {
+ new CombinedData { Display = LocalizationHelper.GetString("DefaultNoExtraTags"), Value = "0" },
+ new CombinedData { Display = LocalizationHelper.GetString("SelectExtraTags"), Value = "1" },
+ new CombinedData { Display = LocalizationHelper.GetString("SelectExtraOnlyRareTags"), Value = "2" },
+ };
+ }
+
private void InitConfiguration()
{
var configurations = new ObservableCollection();
@@ -1319,6 +1330,11 @@ namespace MaaWpfGui.ViewModels.UI
// public List RoguelikeCoreCharList { get; set; }
+ ///
+ /// Gets or sets the list of auto recruit selecting extra tags.
+ ///
+ public List AutoRecruitSelectExtraTagsList { get; set; }
+
///
/// Gets or sets the list of the client types.
///
@@ -2458,18 +2474,35 @@ namespace MaaWpfGui.ViewModels.UI
set => SetAndNotify(ref _useExpedited, value);
}
- private bool _selectExtraTags = Convert.ToBoolean(ConfigurationHelper.GetValue(ConfigurationKeys.SelectExtraTags, bool.FalseString));
+ private string _selectExtraTags = ConfigurationHelper.GetValue(ConfigurationKeys.SelectExtraTags, "0");
///
- /// Gets or sets a value indicating whether three tags are alway selected when selecting tags.
+ /// Gets or sets a value indicating three tags are alway selected or select only rare tags as many as possible .
///
- public bool SelectExtraTags
+ public string SelectExtraTags
{
- get => _selectExtraTags;
+ get
+ {
+ if (int.TryParse(_selectExtraTags, out _))
+ {
+ return _selectExtraTags;
+ }
+
+ var value = "0";
+ if (bool.TryParse(_selectExtraTags, out bool boolValue))
+ {
+ value = boolValue ? "1" : "0";
+ }
+
+ SetAndNotify(ref _selectExtraTags, value);
+ ConfigurationHelper.SetValue(ConfigurationKeys.SelectExtraTags, value);
+ return value;
+ }
+
set
{
SetAndNotify(ref _selectExtraTags, value);
- ConfigurationHelper.SetValue(ConfigurationKeys.SelectExtraTags, value.ToString());
+ ConfigurationHelper.SetValue(ConfigurationKeys.SelectExtraTags, value);
}
}
diff --git a/src/MaaWpfGui/ViewModels/UI/TaskQueueViewModel.cs b/src/MaaWpfGui/ViewModels/UI/TaskQueueViewModel.cs
index 8ec44e77fe..68678c2ec9 100644
--- a/src/MaaWpfGui/ViewModels/UI/TaskQueueViewModel.cs
+++ b/src/MaaWpfGui/ViewModels/UI/TaskQueueViewModel.cs
@@ -1327,9 +1327,11 @@ namespace MaaWpfGui.ViewModels.UI
cfmList.Add(5);
}
+ int.TryParse(Instances.SettingsViewModel.SelectExtraTags, out var selectExtra);
+
return Instances.AsstProxy.AsstAppendRecruit(
maxTimes, reqList.ToArray(), cfmList.ToArray(), Instances.SettingsViewModel.RefreshLevel3, Instances.SettingsViewModel.ForceRefresh, Instances.SettingsViewModel.UseExpedited,
- Instances.SettingsViewModel.SelectExtraTags, Instances.SettingsViewModel.NotChooseLevel1, Instances.SettingsViewModel.IsLevel3UseShortTime, Instances.SettingsViewModel.IsLevel3UseShortTime2);
+ selectExtra, Instances.SettingsViewModel.NotChooseLevel1, Instances.SettingsViewModel.IsLevel3UseShortTime, Instances.SettingsViewModel.IsLevel3UseShortTime2);
}
private static bool AppendRoguelike()
diff --git a/src/MaaWpfGui/Views/UserControl/AutoRecruitSettingsUserControl.xaml b/src/MaaWpfGui/Views/UserControl/AutoRecruitSettingsUserControl.xaml
index 90f82e3aa1..bb20af5918 100644
--- a/src/MaaWpfGui/Views/UserControl/AutoRecruitSettingsUserControl.xaml
+++ b/src/MaaWpfGui/Views/UserControl/AutoRecruitSettingsUserControl.xaml
@@ -33,15 +33,19 @@
+
-