mirror of
https://github.com/MaaAssistantArknights/MaaAssistantArknights.git
synced 2026-07-19 02:23:01 +08:00
fix: 将公招的资源文件读取改为非增量更新
This commit is contained in:
@@ -10,6 +10,8 @@ bool asst::RecruitConfiger::parse(const json::value& json)
|
||||
{
|
||||
LogTraceFunction;
|
||||
|
||||
clear();
|
||||
|
||||
for (const json::value& oper : json.as_array()) {
|
||||
RecruitOperInfo oper_temp;
|
||||
oper_temp.name = oper.at("name").as_string();
|
||||
@@ -39,3 +41,12 @@ bool asst::RecruitConfiger::parse(const json::value& json)
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void asst::RecruitConfiger::clear()
|
||||
{
|
||||
LogTraceFunction;
|
||||
|
||||
m_all_opers.clear();
|
||||
m_all_tags.clear();
|
||||
m_all_types.clear();
|
||||
}
|
||||
|
||||
@@ -50,6 +50,8 @@ namespace asst
|
||||
protected:
|
||||
virtual bool parse(const json::value& json) override;
|
||||
|
||||
void clear();
|
||||
|
||||
std::unordered_set<std::string> m_all_tags;
|
||||
std::unordered_set<std::string> m_all_types;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user