//
// ThreadDescPopup::finishSave from 0xc6d250 to 0xc6d3c8 (376 bytes)
//
// 3 xrefs:
// > ThreadDescPopup::threadUpdateFinished @ 0xc7ae04
// > ThreadDescPopup::threadUpdateFinished @ 0xc7ae78
// > ??> @ 0xa85f8
//
// 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 13:05:28 +0000
//
__int64 __fastcall ThreadDescPopup::finishSave(ThreadDescPopup *this, char *a2)
{
__int64 *v3; // x21
__int64 v4; // x2
void (__fastcall *v5)(__int64 *, __int64, __int64); // x24
size_t v6; // x0
__int64 v7; // x0
GameLevelManager *v8; // x0
__int64 v9; // x0
__int64 v10; // x2
__int64 v11; // x1
__int64 v14[2]; // [xsp+58h] [xbp+58h] BYREF
void *v15; // [xsp+68h] [xbp+68h]
__int64 v16[2]; // [xsp+70h] [xbp+70h] BYREF
void *v17; // [xsp+80h] [xbp+80h]
*((_BYTE *)this + 1113) = 0;
v3 = *(__int64 **)(cocos2d::CCDirector::sharedDirector(_stack_chk_guard) + 272);
v4 = *v3;
v14[0] = 0;
v14[1] = 0;
v5 = *(void (__fastcall **)(__int64 *, __int64, __int64))(v4 + 464);
v15 = nullptr;
v6 = strlen(a2);
std::string::__init(v14, a2, v6);
v16[0] = 0;
v16[1] = 0;
v17 = nullptr;
std::string::__init(v16, &byte_11B8890, 0);
v7 = TextAlertPopup::create((char *)v14, 150, (char *)v16, 0.5, 0.6);
v5(v3, v7, 1000);
if ( (v16[0] & 1) != 0 )
{
operator delete(v17);
if ( (v14[0] & 1) == 0 )
goto LABEL_3;
}
else if ( (v14[0] & 1) == 0 )
{
goto LABEL_3;
}
operator delete(v15);
LABEL_3:
v8 = *((GameLevelManager **)this + 130);
if ( v8 )
{
v9 = GameLevelManager::sharedState(v8);
v10 = *((_QWORD *)this + 130);
v11 = v10 + 672;
if ( !v10 )
v11 = 0;
*(_QWORD *)(v9 + 1264) = v11;
}
(*(void (__fastcall **)(ThreadDescPopup *, _QWORD))(*(_QWORD *)this + 1368LL))(this, 0);
return _stack_chk_guard;
}