//
// GJAccountManager::onUpdateAccountSettingsCompleted from 0x140309f40 to 0x14030a0ad (365 bytes)
//
// 2 xrefs:
// > GJAccountManager::handleIt @ 0x1403056e1
// > ??> @ 0x14091e62c
//
// 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:30:10 +0000
//
// Hidden C++ exception states: #wind=3
void __fastcall GJAccountManager::onUpdateAccountSettingsCompleted(__int64 a1, const void **a2, __int64 a3)
{
void *v6; // rcx
const void *v7; // rcx
unsigned __int64 v8; // rsi
size_t v9; // r8
void (__fastcall ***v10)(_QWORD); // rcx
__int64 v11; // rcx
void *Block[2]; // [rsp+40h] [rbp-48h] BYREF
__m128i si128; // [rsp+50h] [rbp-38h]
Block[1] = nullptr;
si128 = _mm_load_si128((const __m128i *)&xmmword_140836590);
Block[0] = (void *)0x747465735F636361LL;
cocos2d::CCDictionary::removeObjectForKey(*(_QWORD *)(a1 + 320), Block);
if ( si128.m128i_i64[1] > 0xFuLL )
{
v6 = Block[0];
if ( (unsigned __int64)(si128.m128i_i64[1] + 1) >= 0x1000 )
{
v6 = *((void **)Block[0] - 1);
if ( (unsigned __int64)((char *)Block[0] - (char *)v6 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v6);
}
*(_OWORD *)Block = 0;
si128.m128i_i64[0] = 2;
si128.m128i_i64[1] = 15;
strcpy((char *)Block, "-1");
v7 = a2;
if ( (unsigned __int64)a2[3] > 0xF )
v7 = *a2;
v8 = (unsigned __int64)a2[2];
v9 = v8;
if ( v8 > 2 )
v9 = 2;
if ( !memcmp(v7, Block, v9) && v8 == 2 )
{
v11 = *(_QWORD *)(a1 + 448);
if ( v11 )
(*(void (__fastcall **)(__int64))(*(_QWORD *)v11 + 8LL))(v11);
}
else
{
v10 = *(void (__fastcall ****)(_QWORD))(a1 + 448);
if ( v10 )
(**v10)(v10);
}
sub_14003D310((__int64)a2);
sub_14003D310(a3);
}