fix: 修复自动战斗不会开技能的问题

This commit is contained in:
MistEO
2022-12-25 23:01:42 +08:00
parent bd9397bdd5
commit 3ceaa1ecd8
2 changed files with 9 additions and 3 deletions

View File

@@ -107,6 +107,15 @@ bool asst::BattleProcessTask::to_group()
}
m_oper_in_group.merge(ungrouped);
for (const auto& [group_name, oper_name] : m_oper_in_group) {
auto& this_group = m_combat_data.groups[group_name];
auto iter = ranges::find_if(this_group, [&](const auto& oper) { return oper.name == oper_name; });
if (iter == this_group.end()) {
continue;
}
m_skill_usage.emplace(oper_name, iter->skill_usage);
}
return true;
}