//
// GameLevelManager::deleteComment from 0x3d2554 to 0x3d2754 (512 bytes)
//
// 2 xrefs:
// > GameLevelManager::deleteLevelComment @ 0x3d2792
// > GameLevelManager::deleteAccountComment @ 0x3d279c
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void GameLevelManager::deleteComment(GameLevelManager *a1, int a2, CommentType a3, int a4)
{
char *v7; // r0
cocos2d::CCDictionary *m_friendReqAndUserBlocks; // r8
int v9; // r5
cocos2d::CCDictionary *v10; // r5
cocos2d::CCNode *v11; // r8
cocos2d::CCString *v12; // r0
const char *CString; // r0
cocos2d::CCString *v14; // r0
char *v15; // r0
cocos2d::CCString *v16; // r0
char *v17; // r0
cocos2d::CCString *v18; // r0
char *v19; // r0
char **v20; // r0
char *v21; // [sp+14h] [bp-38h]
char *v23; // [sp+20h] [bp-2Ch]
char *v24; // [sp+28h] [bp-24h] BYREF
char *v25; // [sp+2Ch] [bp-20h] BYREF
const char *v26; // [sp+30h] [bp-1Ch] BYREF
char *v27; // [sp+34h] [bp-18h] BYREF
char *v28; // [sp+38h] [bp-14h] BYREF
const char *v29; // [sp+3Ch] [bp-10h] BYREF
std::string v30; // [sp+40h] [bp-Ch] BYREF
v7 = (char *)GameLevelManager::getDeleteCommentKey(a1, a4, a2, a3);
m_friendReqAndUserBlocks = a1->m_friendReqAndUserBlocks;
v21 = v7;
sub_776584((int)&v30, v7);
v9 = cocos2d::CCDictionary::objectForKey(m_friendReqAndUserBlocks, &v30);
sub_774008(&v30);
if ( !v9 )
{
v10 = a1->m_friendReqAndUserBlocks;
v11 = cocos2d::CCNode::create();
sub_776584((int)&v30, v21);
cocos2d::CCDictionary::setObject((int)v10, v11);
sub_774008(&v30);
GameLevelManager::getBasePostString((GameLevelManager *)&v24);
v12 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"%c%s%s%c%c%s",
(const char *)&dword_54 + 3,
"mfd",
"2893",
103,
98,
&aO1i2r3e45s7t89[10]);
CString = cocos2d::CCString::getCString(v12);
v14 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"&commentID=%i&secret=%s",
(const char *)a2,
CString);
v15 = (char *)cocos2d::CCString::getCString(v14);
sub_774544((int)&v24, v15);
if ( a3 )
{
sub_774544((int)&v24, "&cType=");
v18 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"%i", (const char *)a3);
v19 = (char *)cocos2d::CCString::getCString(v18);
sub_774544((int)&v24, v19);
sub_774544((int)&v24, "&targetAccountID=");
}
else
{
sub_774544((int)&v24, "&levelID=");
}
v16 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"%i", (const char *)a4);
v17 = (char *)cocos2d::CCString::getCString(v16);
sub_774544((int)&v24, v17);
v23 = v24;
if ( a3 )
{
sub_776584((int)&v28, "https://www.boomlings.com/database/deleteGJAccComment20.php");
sub_776584((int)&v29, v23);
sub_776584((int)&v30, v21);
GameLevelManager::ProcessHttpRequest(a1, &v28, &v29, (char **)&v30, 14);
sub_774008(&v30);
sub_774008(&v29);
v20 = &v28;
}
else
{
sub_776584((int)&v25, "https://www.boomlings.com/database/deleteGJComment20.php");
sub_776584((int)&v26, v23);
sub_776584((int)&v27, v21);
GameLevelManager::ProcessHttpRequest(a1, &v25, &v26, &v27, 14);
sub_774008(&v27);
sub_774008(&v26);
v20 = &v25;
}
sub_774008(v20);
sub_774008(&v24);
}
}