//
// GameLevelManager::getFollowing from 0x140251210 to 0x14025151c (780 bytes)
//
// 3 xrefs:
// > GameLevelManager::syncFollowListIfNeeded @ 0x140251ac7
// > GameLevelManager::syncFollowListIfNeeded @ 0x140251af1
// > ??> @ 0x14091c49c
//
// This function is hookable on this platform (idp: pc, 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 11:28:42 +0000
//
// Hidden C++ exception states: #wind=4
char __fastcall GameLevelManager::getFollowing(__int64 a1)
{
__int64 v2; // rbx
void *v3; // r8
__int64 v5; // rbx
__int64 v6; // rax
__int64 v7; // rcx
void *v8; // rcx
cocos2d::CCString *v9; // rax
const char *CString; // rax
cocos2d::CCString *v11; // rax
char *v12; // rax
size_t v13; // rbx
size_t v14; // r8
_QWORD *v15; // rdx
int Reserved; // [rsp+20h] [rbp-69h]
int v17; // [rsp+28h] [rbp-61h]
__int128 v18; // [rsp+40h] [rbp-49h] BYREF
__int64 v19; // [rsp+50h] [rbp-39h]
__int64 v20; // [rsp+58h] [rbp-31h]
__int128 v21; // [rsp+60h] [rbp-29h] BYREF
__int64 v22; // [rsp+70h] [rbp-19h]
__int64 v23; // [rsp+78h] [rbp-11h]
__int128 *v24; // [rsp+80h] [rbp-9h]
__int128 *v25; // [rsp+88h] [rbp-1h]
void *Block[2]; // [rsp+98h] [rbp+Fh] BYREF
__int128 v27; // [rsp+A8h] [rbp+1Fh]
_QWORD Src[4]; // [rsp+B8h] [rbp+2Fh] BYREF
*(_OWORD *)Block = 0;
v27 = 0;
sub_14003D230(Block, "following", 9u);
v2 = cocos2d::CCDictionary::objectForKey(*(_QWORD *)(a1 + 1192), Block);
if ( *((_QWORD *)&v27 + 1) > 0xFu )
{
v3 = Block[0];
if ( (unsigned __int64)(*((_QWORD *)&v27 + 1) + 1LL) >= 0x1000 )
{
v3 = *((void **)Block[0] - 1);
if ( (unsigned __int64)((char *)Block[0] - (char *)v3 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v3);
}
if ( v2 )
return 0;
*(_OWORD *)Block = 0;
v27 = 0;
sub_14003D230(Block, "following", 9u);
v5 = *(_QWORD *)(a1 + 1192);
v6 = cocos2d::CCNode::create();
cocos2d::CCDictionary::setObject(v5, v6, Block);
if ( *((_QWORD *)&v27 + 1) > 0xFu )
{
v8 = Block[0];
if ( (unsigned __int64)(*((_QWORD *)&v27 + 1) + 1LL) >= 0x1000 )
{
v8 = *((void **)Block[0] - 1);
if ( (unsigned __int64)((char *)Block[0] - (char *)v8 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v8);
}
GameLevelManager::getBasePostString(v7, Src);
v17 = 98;
Reserved = 103;
v9 = cocos2d::CCString::createWithFormat(
"%c%s%s%c%c%s",
87,
"mfd",
"2893",
Reserved,
v17,
(const char *)&word_14070D040);
CString = cocos2d::CCString::getCString(v9);
v11 = cocos2d::CCString::createWithFormat("&ack=1&secret=%s", CString);
v12 = (char *)cocos2d::CCString::getCString(v11);
v13 = -1;
v14 = -1;
do
++v14;
while ( v12[v14] );
sub_140044D80(Src, v12, v14);
v24 = &v18;
v25 = &v21;
v18 = 0;
v19 = 0;
v20 = 0;
sub_14003D230(&v18, "following", 9u);
v15 = Src;
if ( Src[3] > 0xFu )
v15 = (_QWORD *)Src[0];
v21 = 0;
v22 = 0;
v23 = 0;
do
++v13;
while ( *((_BYTE *)v15 + v13) );
sub_14003D230(&v21, v15, v13);
*(_OWORD *)Block = 0;
v27 = 0u;
Block[0] = sub_14003D460(0x40u);
*(_QWORD *)&v27 = 53;
*((_QWORD *)&v27 + 1) = 63;
strcpy((char *)Block[0], "https://www.boomlings.com/database/getGJFollowing.php");
GameLevelManager::ProcessHttpRequest(
(cocos2d::CCActionManager **)a1,
(__int64)Block,
(const char *)&v21,
(const char *)&v18,
0x72u);
sub_14003D310((__int64)Src);
return 1;
}