diff --git a/Source/Utility/JsonCppLoader.cpp b/Source/Utility/JsonCppLoader.cpp index 9893718e..f5031961 100644 --- a/Source/Utility/JsonCppLoader.cpp +++ b/Source/Utility/JsonCppLoader.cpp @@ -4,6 +4,29 @@ #include #include +// OFFSET: 0x004F3C70 +// FUNCTION: fn_00486 +bool JsonCppLoader::sub_4F3C70(std::vector& buffer, bool bson) { + if (buffer.empty()) { + this->Fail("error : JsonCppLoader::Load failed (reason : 비어있는 버퍼가 전달되었습니다.)"); + return false; + } + + bool parsed; + if (bson) { + parsed = this->sub_4F3DF0(buffer); + } else { + parsed = this->sub_4F4040(buffer); + } + + if (parsed) { + this->loaded = true; + return true; + } + + return false; +} + // OFFSET: 0x004F4180 // FUNCTION: fn_00491 void JsonCppLoader::Fail(const char* format, ...) { diff --git a/Source/Utility/JsonCppLoader.h b/Source/Utility/JsonCppLoader.h index 73bf3d1f..fb93c9b8 100644 --- a/Source/Utility/JsonCppLoader.h +++ b/Source/Utility/JsonCppLoader.h @@ -180,6 +180,8 @@ public: bool GetIntVectorValue(const JsonValue& node, const std::string& key, std::vector* out); bool GetBoolValue(const JsonValue& node, const std::string& key, bool* out); bool sub_4F3C70(std::vector& buffer, bool bson); + bool sub_4F3DF0(std::vector& buffer); + bool sub_4F4040(std::vector& buffer); bool sub_50C2A0(std::map* out); bool sub_50AE30(std::map* out); bool sub_50B830(std::map* out);