//
// GJGameLevel::createFromFullSaveString from 0x83ea50 to 0x83eb38 (232 bytes)
//
// 3 xrefs:
// > LocalLevelManager::importLevelsFromPaths @ 0x911668
// > LocalLevelManager::tryRecoverAutoSaves @ 0x9129b8
// > ??> @ 0xa1dd0
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 12:55:16 +0000
//
GJGameLevel *__fastcall GJGameLevel::createFromFullSaveString(__int64 a1)
{
__int64 v1; // x2
DS_Dictionary *v3; // x19
GJGameLevel *v4; // x20
char *v5; // x0
char *v6; // x2
GJGameLevel *IntegerForKey; // x0
v1 = *(_BYTE *)a1 >> 1;
if ( (*(_BYTE *)a1 & 1) != 0 )
v1 = *(_QWORD *)(a1 + 8);
if ( !v1 )
return nullptr;
v3 = (DS_Dictionary *)operator new(0xF0u);
DS_Dictionary::DS_Dictionary(v3);
if ( (unsigned __int8)DS_Dictionary::loadRootSubDictFromString(v3, a1)
&& (IntegerForKey = (GJGameLevel *)DS_Dictionary::getIntegerForKey(v3, "kCEK"), (_DWORD)IntegerForKey == 4) )
{
v4 = (GJGameLevel *)GJGameLevel::create(IntegerForKey);
GJGameLevel::dataLoaded(v4, v3);
}
else
{
v4 = nullptr;
}
v5 = *((char **)v3 + 26);
if ( v5 )
{
v6 = *((char **)v3 + 27);
if ( v5 != v6 )
*((_QWORD *)v3 + 27) = &v6[8 * ~((unsigned __int64)(v6 - 8 - v5) >> 3)];
operator delete(v5);
}
pugi::xml_document::~xml_document(v3);
operator delete(v3);
return v4;
}