{"type": "func", "start": 4299760832, "end": 4299761465, "name": "AccountLoginLayer::loginAccountFinished", "pseudocode": "// \n// AccountLoginLayer::loginAccountFinished from 0x1004924c0 to 0x100492739 (633 bytes)\n// \n// 2 xrefs:\n// > sub_100492820 @ 0x10049282c\n// > <???> @ 0x100b4f018\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 12:30:47 +0000\n// \n\n__int64 __fastcall AccountLoginLayer::loginAccountFinished(__int64 a1, __int64 a2, int a3, __m128 a4)\n{\n  __int64 v5; // r12\n  __int64 v6; // rax\n  const char *CString; // r14\n  size_t v8; // rax\n  size_t v9; // r15\n  char *v10; // r12\n  size_t v11; // r13\n  __int64 v12; // rbx\n  char v14; // [rsp+0h] [rbp-A0h]\n  void *v15[3]; // [rsp+8h] [rbp-98h] BYREF\n  std::string v16; // [rsp+20h] [rbp-80h] BYREF\n  std::string v17; // [rsp+40h] [rbp-60h] BYREF\n  _QWORD __dst[2]; // [rsp+60h] [rbp-40h] BYREF\n  void *v19; // [rsp+70h] [rbp-30h]\n\n  v5 = GJAccountManager::sharedState(a1, a2);\n  if ( (*(_BYTE *)(a1 + 720) & 1) != 0 )\n  {\n    sub_10001AD30(&v16, *(const void **)(a1 + 736), *(_QWORD *)(a1 + 728));\n    if ( (*(_BYTE *)(a1 + 744) & 1) != 0 )\n      goto LABEL_3;\n  }\n  else\n  {\n    v16.__r_.__value_.__r.__words[2] = *(_QWORD *)(a1 + 736);\n    a4 = *(__m128 *)(a1 + 720);\n    *(__m128 *)&v16.__r_.__value_.__l.0 = a4;\n    if ( (*(_BYTE *)(a1 + 744) & 1) != 0 )\n    {\nLABEL_3:\n      sub_10001AD30(&v17, *(const void **)(a1 + 760), *(_QWORD *)(a1 + 752));\n      goto LABEL_6;\n    }\n  }\n  v17.__r_.__value_.__r.__words[2] = *(_QWORD *)(a1 + 760);\n  a4 = *(__m128 *)(a1 + 744);\n  *(__m128 *)&v17.__r_.__value_.__l.0 = a4;\nLABEL_6:\n  GJAccountManager::linkToAccount(v5, &v16, &v17, a2, a3, *(double *)a4.i64);\n  if ( (*(_BYTE *)&v17.__r_.__value_.__s.0 & 1) != 0 )\n    operator delete(v17.__r_.__value_.__l.__data_);\n  if ( (*(_BYTE *)&v16.__r_.__value_.__s.0 & 1) != 0 )\n    operator delete(v16.__r_.__value_.__l.__data_);\n  CCTextInputNode::getString(v15, *(_QWORD *)(a1 + 680));\n  v6 = sub_10088E820(\"Thank you for logging in.\\nYou have now linked your account:\\n<cg>%s</c>\", v14);\n  CString = (const char *)cocos2d::CCString::getCString(v6);\n  if ( ((__int64)v15[0] & 1) != 0 )\n    operator delete(v15[2]);\n  (*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 552) + 1272LL))(*(_QWORD *)(a1 + 552), 1);\n  (*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 680) + 1000LL))(*(_QWORD *)(a1 + 680), 1);\n  (*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 688) + 1000LL))(*(_QWORD *)(a1 + 688), 1);\n  (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)a1 + 1000LL))(a1, 1);\n  (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)a1 + 1072LL))(a1, 1);\n  (*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 712) + 344LL))(*(_QWORD *)(a1 + 712), 0);\n  v8 = strlen(CString);\n  if ( v8 >= 0xFFFFFFFFFFFFFFF8LL )\n    sub_100003630();\n  v9 = v8;\n  if ( v8 >= 0x17 )\n  {\n    v11 = 26;\n    if ( (v8 | 7) != 0x17 )\n      v11 = (v8 | 7) + 1;\n    v10 = (char *)operator new(v11);\n    v19 = v10;\n    __dst[0] = v11 + 1;\n    __dst[1] = v9;\n    goto LABEL_19;\n  }\n  LOBYTE(__dst[0]) = 2 * v8;\n  v10 = (char *)__dst + 1;\n  if ( v8 )\nLABEL_19:\n    memmove(v10, CString, v9);\n  v10[v9] = 0;\n  v12 = FLAlertLayer::create_1(a1 + 672, \"Login Success\", __dst, \"OK\", 0, 320.0);\n  if ( (__dst[0] & 1) != 0 )\n    operator delete(v19);\n  (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v12 + 72LL))(v12, 2);\n  return (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v12 + 1312LL))(v12);\n}", "assembly": "; \n; AccountLoginLayer::loginAccountFinished from 0x1004924c0 to 0x100492739 (633 bytes)\n; \n; 2 xrefs:\n; > sub_100492820 @ 0x10049282c\n; > <???> @ 0x100b4f018\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 12:30:47 +0000\n; \npush    rbp                                                            ; +0x0, 0x1004924c0\nmov     rbp, rsp                                                       ; +0x1, 0x1004924c1\npush    r15                                                            ; +0x4, 0x1004924c4\npush    r14                                                            ; +0x6, 0x1004924c6\npush    r13                                                            ; +0x8, 0x1004924c8\npush    r12                                                            ; +0xa, 0x1004924ca\npush    rbx                                                            ; +0xc, 0x1004924cc\nsub     rsp, 78h                                                       ; +0xd, 0x1004924cd\nmov     r14d, edx                                                      ; +0x11, 0x1004924d1\nmov     r15d, esi                                                      ; +0x14, 0x1004924d4\nmov     rbx, rdi                                                       ; +0x17, 0x1004924d7\ncall    GJAccountManager__sharedState                                  ; +0x1a, 0x1004924da\nmov     r12, rax                                                       ; +0x1f, 0x1004924df\ntest    byte ptr [rbx+2D0h], 1                                         ; +0x22, 0x1004924e2\njnz     short loc_100492523                                            ; +0x29, 0x1004924e9\nlea     rax, [rbx+2D0h]                                                ; +0x2b, 0x1004924eb\nmov     rcx, [rax+10h]                                                 ; +0x32, 0x1004924f2\nmov     [rbp+var_70], rcx                                              ; +0x36, 0x1004924f6\nmovups  xmm0, xmmword ptr [rax]                                        ; +0x3a, 0x1004924fa\nmovaps  [rbp+var_80], xmm0                                             ; +0x3d, 0x1004924fd\ntest    byte ptr [rbx+2E8h], 1                                         ; +0x41, 0x100492501\njz      short loc_100492543                                            ; +0x48, 0x100492508\nmov     rdx, [rbx+2F0h]                                                ; +0x4a, 0x10049250a\nmov     rsi, [rbx+2F8h]                                                ; +0x51, 0x100492511\nlea     rdi, [rbp+var_60]                                              ; +0x58, 0x100492518\ncall    sub_10001AD30                                                  ; +0x5c, 0x10049251c\njmp     short loc_100492559                                            ; +0x61, 0x100492521\nmov     rdx, [rbx+2D8h]                                                ; +0x63, 0x100492523\nmov     rsi, [rbx+2E0h]                                                ; +0x6a, 0x10049252a\nlea     rdi, [rbp+var_80]                                              ; +0x71, 0x100492531\ncall    sub_10001AD30                                                  ; +0x75, 0x100492535\ntest    byte ptr [rbx+2E8h], 1                                         ; +0x7a, 0x10049253a\njnz     short loc_10049250A                                            ; +0x81, 0x100492541\nlea     rax, [rbx+2E8h]                                                ; +0x83, 0x100492543\nmov     rcx, [rax+10h]                                                 ; +0x8a, 0x10049254a\nmov     [rbp+__p], rcx                                                 ; +0x8e, 0x10049254e\nmovups  xmm0, xmmword ptr [rax]                                        ; +0x92, 0x100492552\nmovaps  [rbp+var_60], xmm0                                             ; +0x95, 0x100492555\nlea     rsi, [rbp+var_80]                                              ; +0x99, 0x100492559\nlea     rdx, [rbp+var_60]                                              ; +0x9d, 0x10049255d\nmov     rdi, r12                                                       ; +0xa1, 0x100492561\nmov     ecx, r15d                                                      ; +0xa4, 0x100492564\nmov     r8d, r14d                                                      ; +0xa7, 0x100492567\ncall    GJAccountManager__linkToAccount                                ; +0xaa, 0x10049256a\ntest    byte ptr [rbp+var_60], 1                                       ; +0xaf, 0x10049256f\njz      short loc_10049257E                                            ; +0xb3, 0x100492573\nmov     rdi, [rbp+__p]; __p                                            ; +0xb5, 0x100492575\ncall    __ZdlPv; operator delete(void *)                               ; +0xb9, 0x100492579\ntest    byte ptr [rbp+var_80], 1                                       ; +0xbe, 0x10049257e\njz      short loc_10049258D                                            ; +0xc2, 0x100492582\nmov     rdi, [rbp+var_70]; __p                                         ; +0xc4, 0x100492584\ncall    __ZdlPv; operator delete(void *)                               ; +0xc8, 0x100492588\nmov     rsi, [rbx+2A8h]                                                ; +0xcd, 0x10049258d\nlea     rdi, [rbp+var_98]                                              ; +0xd4, 0x100492594\ncall    CCTextInputNode__getString                                     ; +0xdb, 0x10049259b\ntest    [rbp+var_98], 1                                                ; +0xe0, 0x1004925a0\njz      short loc_1004925B2                                            ; +0xe7, 0x1004925a7\nmov     rsi, [rbp+var_88]                                              ; +0xe9, 0x1004925a9\njmp     short loc_1004925B9                                            ; +0xf0, 0x1004925b0\nlea     rsi, [rbp+var_97]                                              ; +0xf2, 0x1004925b2\nlea     rdi, aThankYouForLog; \"Thank you for logging in.\\nYou have now\"... ; +0xf9, 0x1004925b9\nxor     eax, eax                                                       ; +0x100, 0x1004925c0\ncall    sub_10088E820                                                  ; +0x102, 0x1004925c2\nmov     rdi, rax                                                       ; +0x107, 0x1004925c7\ncall    cocos2d__CCString__getCString                                  ; +0x10a, 0x1004925ca\nmov     r14, rax                                                       ; +0x10f, 0x1004925cf\ntest    [rbp+var_98], 1                                                ; +0x112, 0x1004925d2\njz      short loc_1004925E7                                            ; +0x119, 0x1004925d9\nmov     rdi, [rbp+var_88]; __p                                         ; +0x11b, 0x1004925db\ncall    __ZdlPv; operator delete(void *)                               ; +0x122, 0x1004925e2\nmov     rdi, [rbx+228h]                                                ; +0x127, 0x1004925e7\nmov     rax, [rdi]                                                     ; +0x12e, 0x1004925ee\nmov     esi, 1                                                         ; +0x131, 0x1004925f1\ncall    qword ptr [rax+4F8h]                                           ; +0x136, 0x1004925f6\nmov     rdi, [rbx+2A8h]                                                ; +0x13c, 0x1004925fc\nmov     rax, [rdi]                                                     ; +0x143, 0x100492603\nmov     esi, 1                                                         ; +0x146, 0x100492606\ncall    qword ptr [rax+3E8h]                                           ; +0x14b, 0x10049260b\nmov     rdi, [rbx+2B0h]                                                ; +0x151, 0x100492611\nmov     rax, [rdi]                                                     ; +0x158, 0x100492618\nmov     esi, 1                                                         ; +0x15b, 0x10049261b\ncall    qword ptr [rax+3E8h]                                           ; +0x160, 0x100492620\nmov     rax, [rbx]                                                     ; +0x166, 0x100492626\nmov     rdi, rbx                                                       ; +0x169, 0x100492629\nmov     esi, 1                                                         ; +0x16c, 0x10049262c\ncall    qword ptr [rax+3E8h]                                           ; +0x171, 0x100492631\nmov     rax, [rbx]                                                     ; +0x177, 0x100492637\nmov     rdi, rbx                                                       ; +0x17a, 0x10049263a\nmov     esi, 1                                                         ; +0x17d, 0x10049263d\ncall    qword ptr [rax+430h]                                           ; +0x182, 0x100492642\nmov     rdi, [rbx+2C8h]                                                ; +0x188, 0x100492648\nmov     rax, [rdi]                                                     ; +0x18f, 0x10049264f\nxor     esi, esi                                                       ; +0x192, 0x100492652\ncall    qword ptr [rax+158h]                                           ; +0x194, 0x100492654\nmov     rdi, r14; __s                                                  ; +0x19a, 0x10049265a\ncall    _strlen                                                        ; +0x19d, 0x10049265d\ncmp     rax, 0FFFFFFFFFFFFFFF8h                                        ; +0x1a2, 0x100492662\njnb     loc_100492734                                                  ; +0x1a6, 0x100492666\nmov     r15, rax                                                       ; +0x1ac, 0x10049266c\nadd     rbx, 2A0h                                                      ; +0x1af, 0x10049266f\ncmp     rax, 17h                                                       ; +0x1b6, 0x100492676\njnb     short loc_10049268E                                            ; +0x1ba, 0x10049267a\nlea     eax, [r15+r15]                                                 ; +0x1bc, 0x10049267c\nmov     byte ptr [rbp+__dst], al                                       ; +0x1c0, 0x100492680\nlea     r12, [rbp+__dst+1]                                             ; +0x1c3, 0x100492683\ntest    r15, r15                                                       ; +0x1c7, 0x100492687\njnz     short loc_1004926C1                                            ; +0x1ca, 0x10049268a\njmp     short loc_1004926CF                                            ; +0x1cc, 0x10049268c\nmov     rax, r15                                                       ; +0x1ce, 0x10049268e\nor      rax, 7                                                         ; +0x1d1, 0x100492691\nlea     rcx, [rax+1]                                                   ; +0x1d5, 0x100492695\ncmp     rax, 17h                                                       ; +0x1d9, 0x100492699\nmov     r13d, 1Ah                                                      ; +0x1dd, 0x10049269d\ncmovnz  r13, rcx                                                       ; +0x1e3, 0x1004926a3\nmov     rdi, r13; __sz                                                 ; +0x1e7, 0x1004926a7\ncall    __Znwm; operator new(ulong)                                    ; +0x1ea, 0x1004926aa\nmov     r12, rax                                                       ; +0x1ef, 0x1004926af\nmov     [rbp+var_30], rax                                              ; +0x1f2, 0x1004926b2\ninc     r13                                                            ; +0x1f6, 0x1004926b6\nmov     [rbp+__dst], r13                                               ; +0x1f9, 0x1004926b9\nmov     [rbp+var_38], r15                                              ; +0x1fd, 0x1004926bd\nmov     rdi, r12; __dst                                                ; +0x201, 0x1004926c1\nmov     rsi, r14; __src                                                ; +0x204, 0x1004926c4\nmov     rdx, r15; __len                                                ; +0x207, 0x1004926c7\ncall    _memmove                                                       ; +0x20a, 0x1004926ca\nmov     byte ptr [r12+r15], 0                                          ; +0x20f, 0x1004926cf\nlea     rsi, aLoginSuccess; \"Login Success\"                            ; +0x214, 0x1004926d4\nlea     rcx, aOk; \"OK\"                                                 ; +0x21b, 0x1004926db\nlea     rdx, [rbp+__dst]                                               ; +0x222, 0x1004926e2\nmovss   xmm0, cs:dword_100A04128                                       ; +0x226, 0x1004926e6\nmov     rdi, rbx                                                       ; +0x22e, 0x1004926ee\nxor     r8d, r8d                                                       ; +0x231, 0x1004926f1\ncall    FLAlertLayer__create_1                                         ; +0x234, 0x1004926f4\nmov     rbx, rax                                                       ; +0x239, 0x1004926f9\ntest    byte ptr [rbp+__dst], 1                                        ; +0x23c, 0x1004926fc\njz      short loc_10049270B                                            ; +0x240, 0x100492700\nmov     rdi, [rbp+var_30]; __p                                         ; +0x242, 0x100492702\ncall    __ZdlPv; operator delete(void *)                               ; +0x246, 0x100492706\nmov     rax, [rbx]                                                     ; +0x24b, 0x10049270b\nmov     rdi, rbx                                                       ; +0x24e, 0x10049270e\nmov     esi, 2                                                         ; +0x251, 0x100492711\ncall    qword ptr [rax+48h]                                            ; +0x256, 0x100492716\nmov     rax, [rbx]                                                     ; +0x259, 0x100492719\nmov     rdi, rbx                                                       ; +0x25c, 0x10049271c\ncall    qword ptr [rax+520h]                                           ; +0x25f, 0x10049271f\nadd     rsp, 78h                                                       ; +0x265, 0x100492725\npop     rbx                                                            ; +0x269, 0x100492729\npop     r12                                                            ; +0x26a, 0x10049272a\npop     r13                                                            ; +0x26c, 0x10049272c\npop     r14                                                            ; +0x26e, 0x10049272e\npop     r15                                                            ; +0x270, 0x100492730\npop     rbp                                                            ; +0x272, 0x100492732\nretn                                                                   ; +0x273, 0x100492733\ncall    sub_100003630                                                  ; +0x274, 0x100492734", "xrefs": ["sub_100492820 @ 0x10049282c", "<???> @ 0x100b4f018"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}