fix: 修复保全派驻干员技能用法错误

This commit is contained in:
MistEO
2023-05-02 04:36:35 +08:00
parent 2b9368e1b2
commit 3dcd5eab11

View File

@@ -93,10 +93,18 @@ bool asst::BattleProcessTask::to_group()
}
auto result_opt = algorithm::get_char_allocation_for_each_group(groups, char_set);
if (!result_opt) {
return false;
if (result_opt) {
m_oper_in_group = *result_opt;
}
else {
Log.warn("get_char_allocation_for_each_group failed");
for (const auto& [gp, names] : groups) {
if (names.empty()) {
continue;
}
m_oper_in_group.emplace(gp, names.front());
}
}
m_oper_in_group = *result_opt;
std::unordered_map<std::string, std::string> ungrouped;
const auto& grouped_view = m_oper_in_group | views::values;