//
// GJAccountManager::onSyncAccountCompleted from 0x1403087e0 to 0x140309581 (3489 bytes)
//
// 2 xrefs:
// > GJAccountManager::handleIt @ 0x1403056aa
// > ??> @ 0x14091e5f0
//
// This function is hookable on this platform (idp: pc, 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 11:30:10 +0000
//
// Hidden C++ exception states: #wind=32
void __fastcall GJAccountManager::onSyncAccountCompleted(__int64 a1, __int64 *a2, __int64 a3)
{
__int64 v3; // r12
void *v6; // rcx
const void *v7; // rcx
unsigned __int64 v8; // r15
size_t v9; // r8
int v10; // edi
unsigned __int64 v11; // rbx
__int64 v12; // rcx
__int64 v13; // rdx
cocos2d::CCString *v14; // rax
const char *CString; // rax
size_t v16; // r8
void **v17; // rdx
const void *v18; // rcx
size_t v19; // rdi
size_t v20; // r8
size_t v21; // r14
const char *v22; // rcx
__int64 *v23; // rbx
const char *v24; // rcx
__int64 v25; // rbx
__int64 v26; // rdi
unsigned int v27; // eax
cocos2d::CCArray *v28; // r14
__int64 v29; // rcx
__int64 v30; // rdx
__int64 v31; // rcx
__int64 v32; // r8
__int64 v33; // rdx
__int64 v34; // rcx
__int64 v35; // r8
__int64 v36; // rdx
__int64 v37; // r8
__int64 v38; // rcx
__int64 v39; // rax
cocos2d::CCString *v40; // rax
const char *v41; // rax
size_t v42; // r8
_QWORD *v43; // rax
cocos2d::CCString *v44; // rax
const char *v45; // rax
size_t v46; // r8
_QWORD *v47; // rax
__int64 v48; // rcx
__int64 v49; // rcx
__int64 v50; // rax
void *v51; // rcx
cocos2d::CCString *v52; // rax
cocos2d::CCString *v53; // rax
cocos2d::CCString *v54; // rax
const char *v55; // rax
size_t v56; // r8
__int64 v57; // rdx
void **v58; // rcx
unsigned __int64 v59; // rax
size_t v60; // r8
void **v61; // rdx
void **v62; // rax
__int64 v63; // rax
void **v64; // rax
void *v65; // rcx
unsigned __int64 v66; // rdi
unsigned __int64 v67; // r13
cocos2d::CCString *v68; // rax
const char *v69; // rax
size_t v70; // r8
__int64 v71; // rdx
void **v72; // rax
void *v73; // rcx
size_t v74; // r8
void **v75; // rdx
void **v76; // rax
__int64 v77; // rax
__m128i v78; // xmm1
void **v79; // rax
void **v80; // r14
void **v81; // r12
__int64 v82; // rbx
cocos2d::CCArray *MapPacks; // rax
cocos2d::CCArray *v84; // r15
void **v85; // rcx
unsigned int v86; // edi
struct cocos2d::CCObject *v87; // rbx
cocos2d::CCArray *v88; // rcx
signed int v89; // r14d
cocos2d::CCArray *v90; // rcx
signed int v91; // eax
__int64 v92; // rcx
__int64 v93; // rcx
_QWORD *v94; // rbx
__int64 v95; // r8
__int64 v96; // rcx
__int64 v97; // rcx
__int64 v98; // rdx
__int64 v99; // r8
__int64 v100; // rcx
__int64 v101; // rcx
__int64 v102; // rax
__int64 v103; // rax
void **v104; // rdx
__int64 v105; // rdx
__int64 v106; // r8
__int64 v107; // rcx
__int64 v108; // rdx
__int64 v109; // r8
__int64 v110; // rax
void (__fastcall ***v111)(_QWORD); // rcx
void (__fastcall ***v112)(_QWORD); // rcx
unsigned __int8 v113; // [rsp+30h] [rbp-D0h]
char v114; // [rsp+31h] [rbp-CFh]
void *v115; // [rsp+38h] [rbp-C8h]
void *v116; // [rsp+38h] [rbp-C8h]
void *v117; // [rsp+38h] [rbp-C8h]
void *v118; // [rsp+38h] [rbp-C8h]
void *v119; // [rsp+38h] [rbp-C8h]
void *v120; // [rsp+38h] [rbp-C8h]
void *v121; // [rsp+38h] [rbp-C8h]
void *v122; // [rsp+40h] [rbp-C0h]
void *v123; // [rsp+40h] [rbp-C0h]
void *v124; // [rsp+40h] [rbp-C0h]
void *v125; // [rsp+40h] [rbp-C0h]
void *v126; // [rsp+40h] [rbp-C0h]
void *v127; // [rsp+48h] [rbp-B8h]
void *v128; // [rsp+48h] [rbp-B8h]
void *v129; // [rsp+48h] [rbp-B8h]
void *v130[4]; // [rsp+50h] [rbp-B0h] BYREF
__int64 v131; // [rsp+70h] [rbp-90h]
__int64 v132; // [rsp+78h] [rbp-88h]
__int64 *v133; // [rsp+80h] [rbp-80h]
__int64 v134; // [rsp+88h] [rbp-78h]
void *Block[2]; // [rsp+90h] [rbp-70h] BYREF
__int64 v136; // [rsp+A0h] [rbp-60h]
unsigned __int64 v137; // [rsp+A8h] [rbp-58h]
void *Buf2[2]; // [rsp+B0h] [rbp-50h] BYREF
size_t Size; // [rsp+C0h] [rbp-40h]
unsigned __int64 v140; // [rsp+C8h] [rbp-38h]
void *v141[2]; // [rsp+D0h] [rbp-30h] BYREF
unsigned __int64 v142; // [rsp+E0h] [rbp-20h]
unsigned __int64 v143; // [rsp+E8h] [rbp-18h]
void *Src[2]; // [rsp+F0h] [rbp-10h] BYREF
__m128i v145; // [rsp+100h] [rbp+0h]
__int128 v146; // [rsp+110h] [rbp+10h] BYREF
__int128 v147; // [rsp+120h] [rbp+20h]
__int128 v148; // [rsp+130h] [rbp+30h] BYREF
__int64 v149; // [rsp+140h] [rbp+40h]
__int64 v150; // [rsp+148h] [rbp+48h]
__int128 v151; // [rsp+150h] [rbp+50h] BYREF
__int64 v152; // [rsp+160h] [rbp+60h]
__int64 v153; // [rsp+168h] [rbp+68h]
_BYTE v154[32]; // [rsp+170h] [rbp+70h] BYREF
v3 = a3;
v132 = a3;
v131 = a1;
v133 = a2;
v134 = a3;
v136 = 12;
v137 = 15;
Block[0] = *(void **)"sync_account";
Block[1] = (void *)*(unsigned int *)"ount";
cocos2d::CCDictionary::removeObjectForKey(*(_QWORD *)(a1 + 320), Block);
if ( v137 > 0xF )
{
v6 = Block[0];
if ( v137 + 1 >= 0x1000 )
{
v6 = *((void **)Block[0] - 1);
if ( (unsigned __int64)((char *)Block[0] - (char *)v6 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v6);
}
*(_OWORD *)Block = 0;
v136 = 2;
v137 = 15;
strcpy((char *)Block, "-1");
v7 = a2;
if ( (unsigned __int64)a2[3] > 0xF )
v7 = (const void *)*a2;
v8 = a2[2];
v9 = v8;
if ( v8 > 2 )
v9 = 2;
v10 = memcmp(v7, Block, v9);
v11 = -1;
if ( !v10 )
{
if ( v8 >= 2 )
v10 = v8 > 2;
else
v10 = -1;
}
if ( !v10 )
{
LABEL_15:
v12 = *(_QWORD *)(a1 + 440);
if ( v12 )
{
v13 = 0xFFFFFFFFLL;
LABEL_152:
(*(void (__fastcall **)(__int64, __int64, _QWORD))(*(_QWORD *)v12 + 8LL))(v12, v13, 0);
goto LABEL_153;
}
goto LABEL_153;
}
v14 = cocos2d::CCString::createWithFormat((const char *)&word_1406ED6F8, 4294967294LL);
CString = cocos2d::CCString::getCString(v14);
*(_OWORD *)Buf2 = 0;
Size = 0;
v140 = 0;
v16 = -1;
do
++v16;
while ( CString[v16] );
sub_14003D230(Buf2, CString, v16);
v17 = Buf2;
if ( v140 > 0xF )
v17 = (void **)Buf2[0];
v18 = a2;
if ( (unsigned __int64)a2[3] > 0xF )
v18 = (const void *)*a2;
v19 = a2[2];
v20 = v19;
v21 = Size;
if ( Size < v19 )
v20 = Size;
if ( memcmp(v18, v17, v20) || v19 < v21 || v19 > v21 )
{
sub_14003D310((__int64)Buf2);
if ( (unsigned __int64)a2[2] < 0xA )
{
v22 = (const char *)a2;
if ( (unsigned __int64)a2[3] > 0xF )
v22 = (const char *)*a2;
if ( atoi(v22) < 0 )
{
v23 = *(__int64 **)(a1 + 440);
if ( v23 )
{
v24 = (const char *)a2;
if ( (unsigned __int64)a2[3] > 0xF )
v24 = (const char *)*a2;
v25 = *v23;
v26 = *(_QWORD *)(a1 + 440);
v27 = atoi(v24);
(*(void (__fastcall **)(__int64, __int64, _QWORD))(v25 + 8))(v26, 4294967293LL, v27);
}
goto LABEL_153;
}
}
v28 = sub_1400D2840(a2, byte_140752308);
if ( cocos2d::CCArray::count(v28) >= 6 )
{
v29 = *(_QWORD *)&qword_14090BFB0;
if ( !*(_QWORD *)&qword_14090BFB0 )
{
v115 = operator new(0x690u);
*(_QWORD *)&qword_14090BFB0 = GameLevelManager::GameLevelManager((__int64)v115);
(*(void (__fastcall **)(_QWORD))(**(_QWORD **)&qword_14090BFB0 + 72LL))(*(_QWORD *)&qword_14090BFB0);
v29 = *(_QWORD *)&qword_14090BFB0;
}
GameLevelManager::makeTimeStamp(v29, "sync_account");
v114 = *(_BYTE *)(AchievementManager::sharedState(v31, v30, v32) + 360);
*(_BYTE *)(AchievementManager::sharedState(v34, v33, v35) + 360) = 1;
v38 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v116 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v116);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v38 = qword_14090BFE0;
}
v113 = *(_BYTE *)(v38 + 912);
*(_BYTE *)(v38 + 912) = 1;
GameStatsManager::preSaveGameStats(v38, v36, v37);
v39 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v117 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v117);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v39 = qword_14090BFE0;
}
*(_BYTE *)(v39 + 320) = 1;
v40 = cocos2d::CCArray::stringAtIndex(v28, 0);
v41 = cocos2d::CCString::getCString(v40);
v151 = 0;
v152 = 0;
v153 = 0;
v42 = -1;
do
++v42;
while ( v41[v42] );
sub_14003D230(&v151, v41, v42);
v43 = (_QWORD *)((char *)cocos2d::CCArray::stringAtIndex(v28, 0) + 56);
v43[2] = 0;
if ( v43[3] > 0xFu )
v43 = (_QWORD *)*v43;
*(_BYTE *)v43 = 0;
v44 = cocos2d::CCArray::stringAtIndex(v28, 1u);
v45 = cocos2d::CCString::getCString(v44);
v148 = 0;
v149 = 0;
v150 = 0;
v46 = -1;
do
++v46;
while ( v45[v46] );
sub_14003D230(&v148, v45, v46);
v47 = (_QWORD *)((char *)cocos2d::CCArray::stringAtIndex(v28, 1u) + 56);
v47[2] = 0;
if ( v47[3] > 0xFu )
v47 = (_QWORD *)*v47;
*(_BYTE *)v47 = 0;
v48 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
v118 = operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager((__int64)v118);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v48 = qword_14090BFD0;
}
GManager::loadFromCompressedString(v48, &v151);
v50 = LocalLevelManager::sharedState(v49);
GManager::loadFromCompressedString(v50, &v148);
if ( !*(_QWORD *)&qword_14090BFB0 )
{
v119 = operator new(0x690u);
*(_QWORD *)&qword_14090BFB0 = GameLevelManager::GameLevelManager((__int64)v119);
(*(void (__fastcall **)(_QWORD))(**(_QWORD **)&qword_14090BFB0 + 72LL))(*(_QWORD *)&qword_14090BFB0);
}
*(_OWORD *)Block = 0;
v136 = 0;
v137 = 15;
LOBYTE(Block[0]) = 0;
sub_140223100(0, (const void **)Block);
if ( v137 > 0xF )
{
v51 = Block[0];
if ( v137 + 1 >= 0x1000 )
{
v51 = *((void **)Block[0] - 1);
if ( (unsigned __int64)((char *)Block[0] - (char *)v51 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v51);
}
v52 = cocos2d::CCArray::stringAtIndex(v28, 2u);
cocos2d::CCString::intValue(v52);
v53 = cocos2d::CCArray::stringAtIndex(v28, 3u);
cocos2d::CCString::intValue(v53);
v146 = 0;
*(_QWORD *)&v147 = 0;
*((_QWORD *)&v147 + 1) = 15;
LOBYTE(v146) = 0;
v54 = cocos2d::CCArray::stringAtIndex(v28, 4u);
v55 = cocos2d::CCString::getCString(v54);
*(_OWORD *)Buf2 = 0;
Size = 0;
v140 = 0;
v56 = -1;
do
++v56;
while ( v55[v56] );
sub_14003D230(Buf2, v55, v56);
v58 = Buf2;
if ( v140 > 0xF )
v58 = (void **)Buf2[0];
v59 = -1;
do
++v59;
while ( *((_BYTE *)v58 + v59) );
if ( v59 > 0x28 )
{
v60 = Size - 40;
*(_OWORD *)v141 = 0;
v142 = 0;
v143 = 0;
if ( Size < 0x14 )
sub_14003F4D0(v58, v57, v60, Buf2[0]);
if ( Size - 20 < v60 )
v60 = Size - 20;
v61 = Buf2;
if ( v140 > 0xF )
v61 = (void **)Buf2[0];
sub_14003D230(v141, (char *)v61 + 20, v60);
Size = 0;
v62 = Buf2;
if ( v140 > 0xF )
v62 = (void **)Buf2[0];
*(_BYTE *)v62 = 0;
v63 = cocos2d::ZipUtils::decompressString(Block, v141, 0, 11);
if ( &v146 != (__int128 *)v63 )
{
v146 = *(_OWORD *)v63;
v147 = *(_OWORD *)(v63 + 16);
*(_QWORD *)(v63 + 16) = 0;
*(_QWORD *)(v63 + 24) = 15;
*(_BYTE *)v63 = 0;
}
sub_14003D310((__int64)Block);
v142 = 0;
v64 = v141;
if ( v143 > 0xF )
v64 = (void **)v141[0];
*(_BYTE *)v64 = 0;
if ( v143 > 0xF )
{
v65 = v141[0];
if ( v143 + 1 >= 0x1000 )
{
v65 = *((void **)v141[0] - 1);
if ( (unsigned __int64)((char *)v141[0] - (char *)v65 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v65);
}
}
*(_OWORD *)Src = 0;
v66 = 0;
v145.m128i_i64[0] = 0;
v67 = 15;
v145.m128i_i64[1] = 15;
LOBYTE(Src[0]) = 0;
v68 = cocos2d::CCArray::stringAtIndex(v28, 5u);
v69 = cocos2d::CCString::getCString(v68);
*(_OWORD *)v141 = 0;
v142 = 0;
v143 = 0;
v70 = -1;
do
++v70;
while ( v69[v70] );
sub_14003D230(v141, v69, v70);
v72 = v141;
v73 = v141[0];
if ( v143 > 0xF )
v72 = (void **)v141[0];
do
++v11;
while ( *((_BYTE *)v72 + v11) );
if ( v11 > 0x28 )
{
v74 = v142 - 40;
*(_OWORD *)Block = 0;
v136 = 0;
v137 = 0;
if ( v142 < 0x14 )
sub_14003F4D0(v141[0], v71, v74, v143);
if ( v142 - 20 < v74 )
v74 = v142 - 20;
v75 = v141;
if ( v143 > 0xF )
v75 = (void **)v141[0];
sub_14003D230(Block, (char *)v75 + 20, v74);
v142 = 0;
v76 = v141;
if ( v143 > 0xF )
v76 = (void **)v141[0];
*(_BYTE *)v76 = 0;
v77 = cocos2d::ZipUtils::decompressString(v154, Block, 0, 11);
if ( Src != (void **)v77 )
{
*(_OWORD *)Src = *(_OWORD *)v77;
v145 = *(__m128i *)(v77 + 16);
v78 = v145;
*(_QWORD *)(v77 + 16) = 0;
*(_QWORD *)(v77 + 24) = 15;
*(_BYTE *)v77 = 0;
v67 = _mm_srli_si128(v78, 8).m128i_u64[0];
v66 = v78.m128i_i64[0];
}
sub_14003D310((__int64)v154);
v136 = 0;
v79 = Block;
if ( v137 > 0xF )
v79 = (void **)Block[0];
*(_BYTE *)v79 = 0;
sub_14003D310((__int64)Block);
}
*(_OWORD *)Block = 0;
v136 = 0;
v137 = 0;
v80 = Src;
v81 = (void **)Src[0];
if ( v67 > 0xF )
v80 = (void **)Src[0];
v82 = 0x7FFFFFFFFFFFFFFFLL;
if ( v66 > 0x7FFFFFFFFFFFFFFFLL )
sub_140009D90(v73);
if ( v66 > 0xF )
{
if ( (v66 | 0xF) <= 0x7FFFFFFFFFFFFFFFLL )
{
v82 = v66 | 0xF;
if ( (v66 | 0xF) < 0x16 )
v82 = 22;
}
Block[0] = sub_14003D460(v82 + 1);
v136 = v66;
v137 = v82;
memcpy(Block[0], v80, v66 + 1);
}
else
{
v136 = v66;
v137 = 15;
*(_OWORD *)Block = *(_OWORD *)v80;
}
if ( !*(_QWORD *)&qword_14090BFB0 )
{
v122 = operator new(0x690u);
*(_QWORD *)&qword_14090BFB0 = GameLevelManager::GameLevelManager((__int64)v122);
(*(void (__fastcall **)(_QWORD))(**(_QWORD **)&qword_14090BFB0 + 72LL))(*(_QWORD *)&qword_14090BFB0);
}
MapPacks = (cocos2d::CCArray *)GameLevelManager::createAndGetMapPacks((__int64)v73, Block);
v84 = MapPacks;
v145.m128i_i64[0] = 0;
v85 = Src;
if ( v67 > 0xF )
v85 = v81;
*(_BYTE *)v85 = 0;
v86 = 0;
if ( cocos2d::CCArray::count(MapPacks) )
{
do
{
v87 = cocos2d::CCArray::objectAtIndex(v84, v86);
v88 = *((cocos2d::CCArray **)v87 + 40);
if ( v88 && cocos2d::CCArray::count(v88) )
{
v89 = GJMapPack::completedMaps((__int64)v87);
v90 = *((cocos2d::CCArray **)v87 + 40);
v91 = v90 ? cocos2d::CCArray::count(v90) : 0;
if ( v89 >= v91 )
{
v92 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v123 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v123);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v92 = qword_14090BFE0;
}
GameStatsManager::completedMapPack(v92, (__int64)v87);
}
}
v93 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v120 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v120);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v93 = qword_14090BFE0;
}
GameStatsManager::setStarsForMapPack(v93, *((_DWORD *)v87 + 82), *((_DWORD *)v87 + 84));
++v86;
}
while ( v86 < cocos2d::CCArray::count(v84) );
}
v94 = (_QWORD *)sub_14003F4F0((__int64)v154, (__int64)&v146);
v96 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
v121 = operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager((__int64)v121);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v96 = qword_14090BFD0;
}
GameManager::recountUserStats(v96, v94, v95);
v97 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v124 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v124);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v97 = qword_14090BFE0;
}
GameStatsManager::verifyUserCoins(v97);
v100 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v125 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v125);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v100 = qword_14090BFE0;
}
GameStatsManager::tryFixPathBug(v100, v98, v99);
v101 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v126 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v126);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v101 = qword_14090BFE0;
}
GameStatsManager::verifyPathAchievements(v101);
v102 = GJAccountManager::sharedState();
sub_14003F4F0((__int64)v130, v102 + 328);
v103 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
v127 = operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager((__int64)v127);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v103 = qword_14090BFD0;
}
if ( (void **)(v103 + 656) != v130 )
{
v104 = v130;
if ( v130[3] > (void *)0xF )
v104 = (void **)v130[0];
sub_1400405A0((void **)(v103 + 656), v104, (size_t)v130[2]);
}
sub_14003D310((__int64)v130);
v107 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v128 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v128);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v107 = qword_14090BFE0;
}
*(_BYTE *)(v107 + 320) = 0;
GameStatsManager::postLoadGameStats(v107, v105, v106);
v110 = qword_14090BFE0;
if ( !qword_14090BFE0 )
{
v129 = operator new(0x3E8u);
qword_14090BFE0 = sub_1402D6480((__int64)v129);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFE0 + 72LL))(qword_14090BFE0);
v110 = qword_14090BFE0;
}
*(_BYTE *)(v110 + 912) = v113;
*(_BYTE *)(AchievementManager::sharedState(v113, v108, v109) + 360) = v114;
v111 = *(void (__fastcall ****)(_QWORD))(v131 + 440);
if ( v111 )
(**v111)(v111);
sub_14003D310((__int64)v141);
sub_14003D310((__int64)Src);
sub_14003D310((__int64)Buf2);
sub_14003D310((__int64)&v146);
sub_14003D310((__int64)&v148);
sub_14003D310((__int64)&v151);
v3 = v132;
goto LABEL_153;
}
goto LABEL_15;
}
sub_14003D310((__int64)Buf2);
sub_1400405A0((void **)(a1 + 464), &byte_1406ED6E0, 0);
sub_1400405A0((void **)(a1 + 376), &byte_1406ED6E0, 0);
v112 = *(void (__fastcall ****)(_QWORD))(a1 + 424);
if ( v112 )
(**v112)(v112);
v12 = *(_QWORD *)(a1 + 440);
if ( v12 )
{
v13 = 4294967294LL;
goto LABEL_152;
}
LABEL_153:
sub_14003D310((__int64)a2);
sub_14003D310(v3);
}