Administrative source import: native x86 compilation passed for 423 authored units. Source placement and submission states are migrated separately; this commit does not imply peer acceptance.
Previous head: 35d2a8cb36
Payload SHA256: 592f016d2730c5593bb653aa054c1e5f76a6df72c8f5a09e66f74876e2e33dee
42 lines
994 B
C++
42 lines
994 B
C++
#include "Contents/Party/AdventurerAgencyMgr.h"
|
|
#include "UI/Party/UIAdvenPartyBoardWnd.h"
|
|
#include "UI/Window/WindowManagerWindows.h"
|
|
#include "Utility/Async/AsyncDiagnostic.h"
|
|
|
|
#include <json/reader.h>
|
|
#include <json/value.h>
|
|
|
|
// OFFSET: 0x005CC000
|
|
// FUNCTION: fn_03662
|
|
void CAdventurerAgencyMgr::CompleteList(AsyncDiagnostic diagnostic, std::string response, WindowManagerWindows& windows) {
|
|
--this->pending;
|
|
|
|
if (!diagnostic.success) {
|
|
return;
|
|
}
|
|
|
|
Json::Value root;
|
|
Json::Reader reader;
|
|
const std::string document(response.c_str());
|
|
|
|
if (!reader.parse(document, root, true)) {
|
|
return;
|
|
}
|
|
|
|
if (root["Type"].asInt() == 2 || root["Type"].asInt() == 3) {
|
|
return;
|
|
}
|
|
|
|
this->LoadList(root["data"]);
|
|
auto* board = static_cast<UIAdvenPartyBoardWnd*>(windows.EnsureWindow(324));
|
|
|
|
if (board) {
|
|
const int pages = root.get("totalPage", 0).asInt();
|
|
|
|
if (pages != 0) {
|
|
board->totalPages = pages;
|
|
}
|
|
|
|
board->SendMsg(nullptr, 60, 0, 0, 0, 0);
|
|
}
|
|
}
|