//
// GJMessagePopup::onBlock from 0xa29848 to 0xa29a54 (524 bytes)
//
// 3 xrefs:
// > ??> @ 0xb5948
// > GJMessagePopup::loadFromGJMessage @ 0xa33504
// > ??> @ 0x1545378
//
// 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:59:43 +0000
//
__int64 __fastcall GJMessagePopup::onBlock(GJMessagePopup *this, cocos2d::CCObject *a2)
{
__int64 v3; // x2
char v4; // w0
__int64 v5; // x0
__int64 v6; // x1
char *v7; // x1
cocos2d::CCString *v8; // x0
size_t v9; // x0
char *v10; // x21
const char *v11; // x1
size_t v12; // x0
ButtonSprite **v13; // x19
char *CString; // [xsp+38h] [xbp+38h]
char *v16; // [xsp+38h] [xbp+38h]
__int64 v17; // [xsp+40h] [xbp+40h] BYREF
__int64 v18; // [xsp+48h] [xbp+48h]
char *v19; // [xsp+50h] [xbp+50h]
__int64 v20[2]; // [xsp+58h] [xbp+58h] BYREF
void *v21; // [xsp+68h] [xbp+68h]
__int64 v22[2]; // [xsp+70h] [xbp+70h] BYREF
void *v23; // [xsp+80h] [xbp+80h]
v17 = 0;
v3 = *((_QWORD *)this + 89) + 376LL;
v18 = 0;
v4 = *(_BYTE *)v3;
v19 = nullptr;
if ( (v4 & 1) != 0 )
{
std::string::__init(&v17, *(void **)(v3 + 16), *(_QWORD *)(v3 + 8));
}
else
{
v5 = *(_QWORD *)v3;
v6 = *(_QWORD *)(v3 + 8);
v19 = *(char **)(v3 + 16);
v17 = v5;
v18 = v6;
}
v7 = (char *)&v17 + 1;
if ( (v17 & 1) != 0 )
v7 = v19;
v8 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"Are you sure you want to block %s?\n"
"%s will no longer be able to:\n"
"- View your profile\n"
"- Send messages\n"
"- Send friend requests\n"
"- Messages from this user will be removed",
v7,
v7);
CString = (char *)cocos2d::CCString::getCString(v8);
v20[0] = 0;
v20[1] = 0;
v21 = nullptr;
v9 = strlen(CString);
std::string::__init(v20, CString, v9);
v10 = (char *)this + 680;
v11 = (char *)v20 + 1;
if ( (v20[0] & 1) != 0 )
v11 = (const char *)v21;
v16 = (char *)v11;
v22[0] = 0;
v22[1] = 0;
v23 = nullptr;
v12 = strlen(v11);
std::string::__init(v22, v16, v12);
v13 = (ButtonSprite **)FLAlertLayer::create(
(__int64)v10,
(cocos2d::CCLabelBMFont *)"Confirm Block",
(char *)v22,
(ButtonSprite *)"Back",
(ButtonSprite *)"Block",
0,
380.0,
0.0,
1.0);
if ( (v22[0] & 1) != 0 )
operator delete(v23);
ButtonSprite::updateBGImage(v13[77], "GJ_button_06.png");
(*((void (__fastcall **)(ButtonSprite **, __int64))*v13 + 9))(v13, 1);
(*((void (__fastcall **)(ButtonSprite **))*v13 + 164))(v13);
if ( (v20[0] & 1) != 0 )
operator delete(v21);
if ( (v17 & 1) != 0 )
operator delete(v19);
return _stack_chk_guard;
}