{"type": "func", "start": 5373075728, "end": 5373076109, "name": "LevelLeaderboard::onChangeType", "pseudocode": "// \n// LevelLeaderboard::onChangeType from 0x14042a110 to 0x14042a28d (381 bytes)\n// \n// 2 xrefs:\n// > LevelLeaderboard::init @ 0x140429216\n// > <???> @ 0x140926a80\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 11:32:12 +0000\n// \n\n// Hidden C++ exception states: #wind=2\n__int64 __fastcall LevelLeaderboard::onChangeType(__int64 a1, __int64 a2)\n{\n  __int64 result; // rax\n  unsigned int v5; // esi\n  __int64 v6; // rbx\n  __int64 v7; // rbx\n  struct cocos2d::CCString *v8; // rax\n  void *v9; // rcx\n  void *v10; // [rsp+30h] [rbp-38h]\n  void *Block[2]; // [rsp+38h] [rbp-30h] BYREF\n  __int64 v12; // [rsp+48h] [rbp-20h]\n  unsigned __int64 v13; // [rsp+50h] [rbp-18h]\n\n  result = GJAccountManager::sharedState();\n  if ( *(_DWORD *)(result + 360) - *(_DWORD *)(result + 364) > 0 )\n  {\n    v5 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a2 + 56LL))(a2);\n    v6 = qword_14090BFD0;\n    if ( !qword_14090BFD0 )\n    {\n      v10 = operator new(0x6E8u);\n      qword_14090BFD0 = GameManager::GameManager((__int64)v10);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);\n      v6 = qword_14090BFD0;\n    }\n    *(_OWORD *)Block = 0;\n    v12 = 3;\n    v13 = 15;\n    LODWORD(Block[0]) = 6256231;\n    sub_140044D80(Block, \"0098\", 4u);\n    v7 = *(_QWORD *)(v6 + 432);\n    v8 = cocos2d::CCString::createWithFormat((const char *)&word_1406ED6F8, v5);\n    cocos2d::CCDictionary::setObject(v7, v8, Block);\n    if ( v13 > 0xF )\n    {\n      v9 = Block[0];\n      if ( v13 + 1 >= 0x1000 )\n      {\n        v9 = *((void **)Block[0] - 1);\n        if ( (unsigned __int64)((char *)Block[0] - (char *)v9 - 8) > 0x1F )\n          invoke_watson(nullptr, nullptr, nullptr, 0, 0);\n      }\n      j_j_free(v9);\n    }\n    return LevelLeaderboard::reloadLeaderboard((__int64 *)a1, v5, *(_DWORD *)(a1 + 692));\n  }\n  return result;\n}", "assembly": "; \n; LevelLeaderboard::onChangeType from 0x14042a110 to 0x14042a28d (381 bytes)\n; \n; 2 xrefs:\n; > LevelLeaderboard::init @ 0x140429216\n; > <???> @ 0x140926a80\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 11:32:12 +0000\n; \nmov     [rsp+arg_10], rbx                                              ; +0x0, 0x14042a110\nmov     [rsp+arg_18], rsi                                              ; +0x5, 0x14042a115\npush    rdi                                                            ; +0xa, 0x14042a11a\nsub     rsp, 60h                                                       ; +0xb, 0x14042a11b\nmov     rax, cs:__security_cookie                                      ; +0xf, 0x14042a11f\nxor     rax, rsp                                                       ; +0x16, 0x14042a126\nmov     [rsp+68h+var_10], rax                                          ; +0x19, 0x14042a129\nmov     rbx, rdx                                                       ; +0x1e, 0x14042a12e\nmov     rdi, rcx                                                       ; +0x21, 0x14042a131\ncall    GJAccountManager__sharedState                                  ; +0x24, 0x14042a134\nmov     ecx, [rax+168h]                                                ; +0x29, 0x14042a139\nsub     ecx, [rax+16Ch]                                                ; +0x2f, 0x14042a13f\ntest    ecx, ecx                                                       ; +0x35, 0x14042a145\njle     loc_14042A26E                                                  ; +0x37, 0x14042a147\nmov     rax, [rbx]                                                     ; +0x3d, 0x14042a14d\nmov     rcx, rbx                                                       ; +0x40, 0x14042a150\ncall    qword ptr [rax+38h]                                            ; +0x43, 0x14042a153\nmov     esi, eax                                                       ; +0x46, 0x14042a156\nmov     rbx, cs:qword_14090BFD0                                        ; +0x48, 0x14042a158\ntest    rbx, rbx                                                       ; +0x4f, 0x14042a15f\njnz     short loc_14042A196                                            ; +0x52, 0x14042a162\nmov     ecx, 6E8h; Size                                                ; +0x54, 0x14042a164\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x59, 0x14042a169\nmov     [rsp+68h+var_38], rax                                          ; +0x5e, 0x14042a16e\nmov     rcx, rax                                                       ; +0x63, 0x14042a173\ncall    GameManager__GameManager                                       ; +0x66, 0x14042a176\nnop                                                                    ; +0x6b, 0x14042a17b\nmov     cs:qword_14090BFD0, rax                                        ; +0x6c, 0x14042a17c\nmov     rcx, [rax]                                                     ; +0x73, 0x14042a183\nmov     rdx, [rcx+48h]                                                 ; +0x76, 0x14042a186\nmov     rcx, rax                                                       ; +0x7a, 0x14042a18a\ncall    rdx                                                            ; +0x7d, 0x14042a18d\nmov     rbx, cs:qword_14090BFD0                                        ; +0x7f, 0x14042a18f\nxorps   xmm0, xmm0                                                     ; +0x86, 0x14042a196\nmovups  xmmword ptr [rsp+68h+Block], xmm0                              ; +0x89, 0x14042a199\nmov     [rsp+68h+var_20], 3                                            ; +0x8e, 0x14042a19e\nmov     [rsp+68h+var_18], 0Fh                                          ; +0x97, 0x14042a1a7\nmov     eax, cs:dword_140757618                                        ; +0xa0, 0x14042a1b0\nmov     word ptr [rsp+68h+Block], ax                                   ; +0xa6, 0x14042a1b6\nmovzx   eax, byte ptr cs:dword_140757618+2                             ; +0xab, 0x14042a1bb\nmov     byte ptr [rsp+68h+Block+2], al                                 ; +0xb2, 0x14042a1c2\nmov     byte ptr [rsp+68h+Block+3], 0                                  ; +0xb6, 0x14042a1c6\nmov     r8d, 4; Size                                                   ; +0xbb, 0x14042a1cb\nlea     rdx, a0098; \"0098\"                                             ; +0xc1, 0x14042a1d1\nlea     rcx, [rsp+68h+Block]; Src                                      ; +0xc8, 0x14042a1d8\ncall    sub_140044D80                                                  ; +0xcd, 0x14042a1dd\nmov     rbx, [rbx+1B0h]                                                ; +0xd2, 0x14042a1e2\nmov     edx, esi                                                       ; +0xd9, 0x14042a1e9\nlea     rcx, word_1406ED6F8                                            ; +0xdb, 0x14042a1eb\ncall    cs:?createWithFormat@CCString@cocos2d@@SAPEAV12@PEBDZZ; cocos2d::CCString::createWithFormat(char const *,...) ; +0xe2, 0x14042a1f2\nmov     rdx, rax                                                       ; +0xe8, 0x14042a1f8\nlea     r8, [rsp+68h+Block]                                            ; +0xeb, 0x14042a1fb\nmov     rcx, rbx                                                       ; +0xf0, 0x14042a200\ncall    cs:?setObject@CCDictionary@cocos2d@@QEAAXPEAVCCObject@2@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z; cocos2d::CCDictionary::setObject(cocos2d::CCObject *,std::string const &) ; +0xf3, 0x14042a203\nnop                                                                    ; +0xf9, 0x14042a209\nmov     rdx, [rsp+68h+var_18]                                          ; +0xfa, 0x14042a20a\ncmp     rdx, 0Fh                                                       ; +0xff, 0x14042a20f\njbe     short loc_14042A25D                                            ; +0x103, 0x14042a213\ninc     rdx                                                            ; +0x105, 0x14042a215\nmov     rcx, [rsp+68h+Block]; Block                                    ; +0x108, 0x14042a218\nmov     rax, rcx                                                       ; +0x10d, 0x14042a21d\ncmp     rdx, 1000h                                                     ; +0x110, 0x14042a220\njb      short loc_14042A258                                            ; +0x117, 0x14042a227\nadd     rdx, 27h ; '''                                                 ; +0x119, 0x14042a229\nmov     rcx, [rcx-8]                                                   ; +0x11d, 0x14042a22d\nsub     rax, rcx                                                       ; +0x121, 0x14042a231\nsub     rax, 8                                                         ; +0x124, 0x14042a234\ncmp     rax, 1Fh                                                       ; +0x128, 0x14042a238\njbe     short loc_14042A258                                            ; +0x12c, 0x14042a23c\nmov     [rsp+68h+Reserved], 0; Reserved                                ; +0x12e, 0x14042a23e\nxor     r9d, r9d; LineNo                                               ; +0x137, 0x14042a247\nxor     r8d, r8d; FileName                                             ; +0x13a, 0x14042a24a\nxor     edx, edx; FunctionName                                         ; +0x13d, 0x14042a24d\nxor     ecx, ecx; Expression                                           ; +0x13f, 0x14042a24f\ncall    cs:_invoke_watson                                              ; +0x141, 0x14042a251\nalign 8                                                                ; +0x147, 0x14042a257\ncall    j_j_free                                                       ; +0x148, 0x14042a258\nmov     r8d, [rdi+2B4h]                                                ; +0x14d, 0x14042a25d\nmov     edx, esi                                                       ; +0x154, 0x14042a264\nmov     rcx, rdi                                                       ; +0x156, 0x14042a266\ncall    LevelLeaderboard__reloadLeaderboard                            ; +0x159, 0x14042a269\nmov     rcx, [rsp+68h+var_10]                                          ; +0x15e, 0x14042a26e\nxor     rcx, rsp; StackCookie                                          ; +0x163, 0x14042a273\ncall    __security_check_cookie                                        ; +0x166, 0x14042a276\nlea     r11, [rsp+68h+var_8]                                           ; +0x16b, 0x14042a27b\nmov     rbx, [r11+20h]                                                 ; +0x170, 0x14042a280\nmov     rsi, [r11+28h]                                                 ; +0x174, 0x14042a284\nmov     rsp, r11                                                       ; +0x178, 0x14042a288\npop     rdi                                                            ; +0x17b, 0x14042a28b\nretn                                                                   ; +0x17c, 0x14042a28c", "xrefs": ["LevelLeaderboard::init @ 0x140429216", "<???> @ 0x140926a80"], "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"}