//
// AccountHelpLayer::onUnlink from 0x58520c to 0x5852c8 (188 bytes)
//
// 0 xrefs:
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:52:57 +0000
//
int __fastcall AccountHelpLayer::onUnlink(AccountHelpLayer *this, cocos2d::CCObject *a2)
{
int v3; // r0
char *v4; // r1
cocos2d::CCString *v5; // r0
const char *CString; // r5
size_t v7; // r0
char **v8; // r5
int v10[2]; // [sp+8h] [bp-14h] BYREF
char *v11; // [sp+10h] [bp-Ch]
v3 = GJAccountManager::sharedState(this);
std::string::basic_string(v10, v3 + 268);
if ( (v10[0] & 1) != 0 )
v4 = v11;
else
v4 = (char *)v10 + 1;
v5 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"Are you sure you want to unlink from the account %s?\n"
"Unlinking will delete all data from this device.",
v4);
CString = (const char *)cocos2d::CCString::getCString(v5);
std::string::~string((int)v10);
v10[0] = 0;
v10[1] = 0;
v11 = nullptr;
v7 = strlen(CString);
std::string::__init(v10, CString, v7);
v8 = (char **)FLAlertLayer::create(
(int)this + 484,
(cocos2d::CCLabelBMFont *)"Unlink Account",
(int)v10,
(ButtonSprite *)"Cancel",
(ButtonSprite *)"Unlink",
300.0);
std::string::~string((int)v10);
ButtonSprite::updateBGImage(v8[121], "GJ_button_05.png");
(*((void (__fastcall **)(char **, int))*v8 + 9))(v8, 3);
return (*((int (__fastcall **)(char **))*v8 + 164))(v8);
}