//
// AccountRegisterLayer::registerAccountFinished from 0x14008dda0 to 0x14008dfd2 (562 bytes)
//
// 2 xrefs:
// > ??> @ 0x1407179f8
// > ??> @ 0x140912980
//
// 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:25:59 +0000
//
// Hidden C++ exception states: #wind=2
__int64 __fastcall AccountRegisterLayer::registerAccountFinished(__int64 a1)
{
__int64 v2; // rcx
_BYTE *v3; // rax
size_t v4; // rbx
size_t v5; // r8
void **v6; // rdx
cocos2d::CCString *v7; // rax
const char *CString; // rdi
void *v9; // r8
int v10; // ebp
__int64 v11; // rax
cocos2d::CCObject *v12; // rbx
__int128 v14; // [rsp+58h] [rbp-70h] BYREF
__int64 v15; // [rsp+68h] [rbp-60h]
__int64 v16; // [rsp+70h] [rbp-58h]
void *Block[2]; // [rsp+80h] [rbp-48h] BYREF
__m128i si128; // [rsp+90h] [rbp-38h]
v2 = *(_QWORD *)(*(_QWORD *)(a1 + 40) + 592LL) + 600LL;
v3 = (_BYTE *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v2 + 8LL))(v2);
*(_OWORD *)Block = 0;
si128 = 0;
v4 = -1;
v5 = -1;
do
++v5;
while ( v3[v5] );
sub_14003D230(Block, v3, v5);
v6 = Block;
if ( si128.m128i_i64[1] > 0xFuLL )
v6 = (void **)Block[0];
v7 = cocos2d::CCString::createWithFormat(
"Thank you for registering.\n"
"A confirmation email has been sent to your inbox %s.\n"
"Please activate your account.",
(const char *)v6);
CString = cocos2d::CCString::getCString(v7);
if ( si128.m128i_i64[1] > 0xFuLL )
{
v9 = Block[0];
if ( (unsigned __int64)(si128.m128i_i64[1] + 1) >= 0x1000 )
{
v9 = *((void **)Block[0] - 1);
if ( (unsigned __int64)((char *)Block[0] - (char *)v9 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v9);
}
si128 = _mm_load_si128((const __m128i *)&Size);
LOBYTE(Block[0]) = 0;
v10 = a1 + 8;
if ( a1 == 664 )
v10 = 0;
v14 = 0;
v15 = 0;
v16 = 0;
do
++v4;
while ( CString[v4] );
sub_14003D230(&v14, CString, v4);
v11 = sub_14003F4F0((__int64)Block, (__int64)&v14);
v12 = FLAlertLayer::create(v10, (int)"Created", v11, (__int64)"OK", 0, 1134559232, 0, 0, 1065353216);
sub_14003D310((__int64)&v14);
(*(void (__fastcall **)(cocos2d::CCObject *, __int64))(*(_QWORD *)v12 + 64LL))(v12, 1);
(*(void (__fastcall **)(cocos2d::CCObject *))(*(_QWORD *)v12 + 1064LL))(v12);
return (*(__int64 (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 104) + 336LL))(*(_QWORD *)(a1 + 104), 0);
}