//
// RenameThreadPopup::threadUpdateFailed from 0xc6d0cc to 0xc6d244 (376 bytes)
//
// 3 xrefs:
// > `non-virtual thunk to'RenameThreadPopup::threadUpdateFailed @ 0xc6d24c
// > ??> @ 0x63340
// > ??> @ 0x14f1638
//
// 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 RenameThreadPopup::threadUpdateFailed(RenameThreadPopup *this, int a2, int a3)
{
__int64 v3; // x0
GameToolbox *v5; // x0
cocos2d::CCDirector *ResponseHadServerPopup; // x0
__int64 *v7; // x20
__int64 v8; // x3
void (__fastcall *v9)(__int64 *, __int64, __int64); // x23
__int64 v10; // x0
__int64 v11[2]; // [xsp+48h] [xbp+48h] BYREF
void *v12; // [xsp+58h] [xbp+58h]
__int64 v13[2]; // [xsp+60h] [xbp+60h] BYREF
void *v14; // [xsp+70h] [xbp+70h]
if ( a3 == 2 && *(_DWORD *)(*((_QWORD *)this + 128) + 56LL) == a2 && *((_BYTE *)this + 1072) )
{
*((_BYTE *)this + 1072) = 0;
v5 = RenameThreadPopup::handBackSlot(this);
ResponseHadServerPopup = (cocos2d::CCDirector *)(unsigned __int8)GameToolbox::lastResponseHadServerPopup(v5);
if ( !(_BYTE)ResponseHadServerPopup )
{
v7 = *(__int64 **)(cocos2d::CCDirector::sharedDirector(ResponseHadServerPopup) + 272);
v8 = *v7;
v11[0] = 0;
v11[1] = 0;
v9 = *(void (__fastcall **)(__int64 *, __int64, __int64))(v8 + 464);
v12 = nullptr;
std::string::__init(v11, "Rename failed", 0xDu);
v13[0] = 0;
v13[1] = 0;
v14 = nullptr;
std::string::__init(v13, &byte_11B8890, 0);
v10 = TextAlertPopup::create((char *)v11, 150, (char *)v13, 0.5, 0.6);
v9(v7, v10, 1000);
if ( (v13[0] & 1) != 0 )
operator delete(v14);
if ( (v11[0] & 1) != 0 )
operator delete(v12);
}
}
else
{
v3 = *((_QWORD *)this + 129);
if ( v3 )
(*(void (__fastcall **)(__int64))(*(_QWORD *)v3 + 1464LL))(v3);
}
return _stack_chk_guard;
}