//
// AccountRegisterLayer::textChanged from 0x993fec to 0x994408 (1052 bytes)
//
// 3 xrefs:
// > `non-virtual thunk to'AccountRegisterLayer::textChanged @ 0x99440c
// > ??> @ 0xde5b0
// > ??> @ 0x1473ec8
//
// 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:58:01 +0000
//
__int64 __fastcall AccountRegisterLayer::textChanged(AccountRegisterLayer *this, CCTextInputNode *a2)
{
int v3; // w0
_BOOL4 v4; // w22
_BYTE *v5; // x2
int v6; // w0
_BOOL4 v8; // w23
_BYTE *v9; // x2
void *v10; // x0
__int64 v12; // [xsp+58h] [xbp+58h] BYREF
size_t v13; // [xsp+60h] [xbp+60h]
void *v14; // [xsp+68h] [xbp+68h]
__int64 v15; // [xsp+70h] [xbp+70h] BYREF
size_t v16; // [xsp+78h] [xbp+78h]
void *v17; // [xsp+80h] [xbp+80h]
__int64 v18[2]; // [xsp+88h] [xbp+88h] BYREF
void *v19; // [xsp+98h] [xbp+98h]
__int64 v20[2]; // [xsp+A0h] [xbp+A0h] BYREF
void *v21; // [xsp+B0h] [xbp+B0h]
__int64 v22[2]; // [xsp+B8h] [xbp+B8h] BYREF
void *v23; // [xsp+C8h] [xbp+C8h]
__int64 v24[2]; // [xsp+D0h] [xbp+D0h] BYREF
void *v25; // [xsp+E0h] [xbp+E0h]
CCTextInputNode::getString(a2, &v12);
v3 = (*(__int64 (__fastcall **)(CCTextInputNode *))(*(_QWORD *)a2 + 64LL))(a2);
if ( v3 == 2 )
{
if ( (v12 & 1) != 0 )
{
if ( v13 )
{
v15 = 0;
v16 = 0;
v17 = nullptr;
std::string::__init(&v15, v14, v13);
LABEL_22:
AccountRegisterLayer::updatePasswordInfo((__int64)this, (unsigned __int8 *)&v15);
if ( (v15 & 1) != 0 )
operator delete(v17);
LABEL_24:
AccountRegisterLayer::resetLabel((_QWORD **)this, 3);
CCTextInputNode::getString(*((CCTextInputNode **)this + 87), v24);
v18[0] = 0;
v18[1] = 0;
v19 = nullptr;
std::string::__init(v18, "Confirm Password:", 0x11u);
v8 = 1;
if ( !sub_98F118((__int64)v24, (__int64)v18) )
{
v20[0] = 0;
v20[1] = 0;
v21 = nullptr;
std::string::__init(v20, "Password:", 9u);
v8 = sub_98F118((__int64)&v12, (__int64)v20);
if ( (v20[0] & 1) != 0 )
operator delete(v21);
}
if ( (v18[0] & 1) != 0 )
operator delete(v19);
if ( !sub_98F118((__int64)&v12, (__int64)v24) )
{
v9 = (char *)&v12 + 1;
v6 = v12 & 1;
if ( v6 )
v9 = v14;
if ( *v9 )
{
if ( (v24[0] & 1) != 0 )
{
v10 = v25;
if ( v8 || !*(_BYTE *)v25 )
goto LABEL_37;
}
else if ( v8 || !BYTE1(v24[0]) )
{
goto LABEL_16;
}
AccountRegisterLayer::updateLabel((__int64)this, -7);
}
}
if ( (v24[0] & 1) == 0 )
goto LABEL_15;
v10 = v25;
goto LABEL_37;
}
}
else if ( (int)(unsigned __int8)v12 >> 1 )
{
v17 = v14;
v15 = v12;
v16 = v13;
goto LABEL_22;
}
(*(void (__fastcall **)(_QWORD, char *))(**((_QWORD **)this + 92) + 928LL))(*((_QWORD *)this + 92), &byte_11B8890);
goto LABEL_24;
}
if ( v3 != 3 )
{
LABEL_15:
v6 = v12 & 1;
goto LABEL_16;
}
CCTextInputNode::getString(*((CCTextInputNode **)this + 86), v20);
v22[0] = 0;
v22[1] = 0;
v23 = nullptr;
std::string::__init(v22, "Password:", 9u);
v4 = 1;
if ( !sub_98F118((__int64)&v12, (__int64)v22) )
{
v24[0] = 0;
v24[1] = 0;
v25 = nullptr;
std::string::__init(v24, "Confirm Password:", 0x11u);
v4 = sub_98F118((__int64)v20, (__int64)v24);
if ( (v24[0] & 1) != 0 )
operator delete(v25);
}
if ( (v22[0] & 1) != 0 )
operator delete(v23);
if ( sub_98F118((__int64)&v12, (__int64)v20) )
goto LABEL_14;
v5 = (char *)&v12 + 1;
v6 = v12 & 1;
if ( v6 )
v5 = v14;
if ( !*v5 )
goto LABEL_14;
if ( (v20[0] & 1) != 0 )
{
v10 = v21;
if ( !v4 && *(_BYTE *)v21 )
goto LABEL_13;
LABEL_37:
operator delete(v10);
LABEL_38:
v6 = v12 & 1;
goto LABEL_16;
}
if ( !v4 && BYTE1(v20[0]) )
{
LABEL_13:
AccountRegisterLayer::updateLabel((__int64)this, -7);
LABEL_14:
if ( (v20[0] & 1) == 0 )
goto LABEL_15;
operator delete(v21);
goto LABEL_38;
}
LABEL_16:
if ( v6 )
operator delete(v14);
return _stack_chk_guard;
}