match some ai::Query

This commit is contained in:
theo3
2021-07-01 19:28:09 -07:00
parent 112c1f987d
commit 60dd80779a
53 changed files with 507 additions and 172 deletions
+11 -2
View File
@@ -1,5 +1,6 @@
#include "Game/AI/Query/queryCheckSellResult.h"
#include <evfl/Query.h>
#include "KingSystem/GameData/gdtCommonFlagsUtils.h"
namespace uking::query {
@@ -7,9 +8,17 @@ CheckSellResult::CheckSellResult(const InitArg& arg) : ksys::act::ai::Query(arg)
CheckSellResult::~CheckSellResult() = default;
// FIXME: implement
int CheckSellResult::doQuery() {
return -1;
if (ksys::gdt::getFlag_Shop_IsDecide()) {
s32 flag = ksys::gdt::getFlag_Shop_CurrentItemState();
if (flag == 0)
return 0;
if (flag == 0xD)
return 1;
if (flag == 0xE)
return 2;
}
return 3;
}
void CheckSellResult::loadParams(const evfl::QueryArg& arg) {}