//
// GameLevelManager::getUserMessages from 0x822aa0 to 0x822d20 (640 bytes)
//
// 2 xrefs:
// > MessagesProfilePage::loadPage @ 0xa4b1ec
// > ??> @ 0xce668
//
// 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:55:02 +0000
//
__int64 __fastcall GameLevelManager::getUserMessages(
GameLevelManager *this,
unsigned __int8 a2,
unsigned int a3,
unsigned int a4)
{
int v5; // w23
char *MessagesKey; // x21
cocos2d::CCString *v10; // x0
__int64 CString; // x0
cocos2d::CCString *v12; // x0
size_t v13; // x0
const char *v14; // x1
size_t v15; // x0
size_t v16; // x0
char *v17; // [xsp+58h] [xbp+58h]
char *v18; // [xsp+58h] [xbp+58h]
__int64 v19[2]; // [xsp+68h] [xbp+68h] BYREF
void *v20; // [xsp+78h] [xbp+78h]
__int64 v21[2]; // [xsp+80h] [xbp+80h] BYREF
void *v22; // [xsp+90h] [xbp+90h]
__int64 v23[2]; // [xsp+98h] [xbp+98h] BYREF
void *v24; // [xsp+A8h] [xbp+A8h]
__int64 v25[2]; // [xsp+B0h] [xbp+B0h] BYREF
void *v26; // [xsp+C0h] [xbp+C0h]
v5 = a2;
MessagesKey = (char *)GameLevelManager::getMessagesKey(this, a2);
if ( !GameLevelManager::isDLActive(this, MessagesKey) )
{
GameLevelManager::addDLToActive(this, MessagesKey);
GameLevelManager::getBasePostString(v19);
v10 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"%c%s%s%c%c%s",
(const char *)off_50 + 7,
"mfd",
"2893",
103,
98,
"7");
CString = cocos2d::CCString::getCString(v10);
v12 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"&page=%i&total=%i&secret=%s",
(const char *)a3,
a4,
CString);
v17 = (char *)cocos2d::CCString::getCString(v12);
v13 = strlen(v17);
std::string::append((__int64)v19, v17, v13);
if ( v5 )
std::string::append((__int64)v19, "&getSent=1", 0xAu);
v21[0] = 0;
v21[1] = 0;
v22 = nullptr;
std::string::__init(v21, "https://www.boomlings.com/database/getGJMessages20.php", 0x36u);
v14 = (char *)v19 + 1;
if ( (v19[0] & 1) != 0 )
v14 = (const char *)v20;
v18 = (char *)v14;
v23[0] = 0;
v23[1] = 0;
v24 = nullptr;
v15 = strlen(v14);
std::string::__init(v23, v18, v15);
v25[0] = 0;
v25[1] = 0;
v26 = nullptr;
v16 = strlen(MessagesKey);
std::string::__init(v25, MessagesKey, v16);
GameLevelManager::ProcessHttpRequest(this, v21, (__int64)v23, (char *)v25, 43);
if ( (v25[0] & 1) != 0 )
operator delete(v26);
if ( (v23[0] & 1) != 0 )
operator delete(v24);
if ( (v21[0] & 1) != 0 )
operator delete(v22);
if ( (v19[0] & 1) != 0 )
operator delete(v20);
}
return _stack_chk_guard;
}