{"type": "func", "start": 5372103088, "end": 5372103567, "name": "GJBaseGameLayer::refreshKeyframeAnims", "pseudocode": "// \n// GJBaseGameLayer::refreshKeyframeAnims from 0x14033c9b0 to 0x14033cb8f (479 bytes)\n// \n// 3 xrefs:\n// > GJBaseGameLayer::updateSpecialGroupData @ 0x140314100\n// > LevelEditorLayer::init @ 0x1403eee12\n// > <???> @ 0x14091fc04\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:30:37 +0000\n// \n\nunsigned int __fastcall GJBaseGameLayer::refreshKeyframeAnims(__int64 a1)\n{\n  __int64 v2; // rcx\n  __int64 v3; // rax\n  __int64 v4; // r14\n  cocos2d::CCDictionary *v5; // r15\n  unsigned int *v6; // r14\n  __int64 v7; // rax\n  struct cocos2d::CCObject **v8; // r14\n  struct cocos2d::CCObject **i; // rbp\n  struct cocos2d::CCObject *v10; // rbx\n  __int64 v11; // rcx\n  struct cocos2d::CCObject *v12; // rdi\n  struct cocos2d::CCArray *v13; // r14\n  unsigned int v14; // ebp\n  unsigned int result; // eax\n  struct cocos2d::CCObject *v16; // rax\n  struct cocos2d::CCObject *v17; // rdi\n  unsigned int j; // ebx\n  struct cocos2d::CCObject *v19; // rax\n\n  cocos2d::CCDictionary::removeAllObjects(*(cocos2d::CCDictionary **)(a1 + 13872));\n  *(_DWORD *)(a1 + 13880) = 0;\n  v3 = cocos2d::CCDictionary::create(v2);\n  v4 = *(_QWORD *)(a1 + 3536);\n  v5 = (cocos2d::CCDictionary *)v3;\n  if ( v4 )\n  {\n    v6 = *(unsigned int **)(v4 + 56);\n    v7 = *v6;\n    if ( (_DWORD)v7 )\n    {\n      v8 = *((struct cocos2d::CCObject ***)v6 + 2);\n      for ( i = &v8[v7 - 1]; v8 <= i; ++v8 )\n      {\n        v10 = *v8;\n        if ( !*v8 )\n          break;\n        if ( *((_DWORD *)v10 + 259) == 3032 )\n        {\n          v12 = cocos2d::CCDictionary::objectForKey(v5, *((int *)v10 + 468));\n          if ( !v12 )\n          {\n            v12 = (struct cocos2d::CCObject *)cocos2d::CCArray::create(v11);\n            (*(void (__fastcall **)(struct cocos2d::CCObject *, _QWORD))(*(_QWORD *)v12 + 64LL))(\n              v12,\n              *((unsigned int *)v10 + 468));\n            cocos2d::CCDictionary::setObject(v5, v12, *((int *)v10 + 468));\n          }\n          cocos2d::CCArray::addObject(v12, v10);\n        }\n      }\n    }\n  }\n  v13 = cocos2d::CCDictionary::allKeys(v5);\n  qsort(\n    *(void **)(*((_QWORD *)v13 + 7) + 16LL),\n    **((unsigned int **)v13 + 7),\n    8u,\n    (_CoreCrtNonSecureSearchSortCompareFunction)sub_14030B1D0);\n  v14 = 0;\n  result = cocos2d::CCArray::count(v13);\n  if ( result )\n  {\n    do\n    {\n      v16 = cocos2d::CCArray::objectAtIndex(v13, v14);\n      v17 = cocos2d::CCDictionary::objectForKey(v5, *((int *)v16 + 14));\n      qsort(\n        *(void **)(*((_QWORD *)v17 + 7) + 16LL),\n        **((unsigned int **)v17 + 7),\n        8u,\n        (_CoreCrtNonSecureSearchSortCompareFunction)sub_14030B1B0);\n      (*(void (__fastcall **)(struct cocos2d::CCObject *, _QWORD))(*(_QWORD *)v17 + 64LL))(\n        v17,\n        *(unsigned int *)(a1 + 13880));\n      cocos2d::CCDictionary::setObject(*(cocos2d::CCDictionary **)(a1 + 13872), v17, *(int *)(a1 + 13880));\n      for ( j = 0; j < cocos2d::CCArray::count(v17); ++j )\n      {\n        v19 = cocos2d::CCArray::objectAtIndex(v17, j);\n        *((_DWORD *)v19 + 468) = *(_DWORD *)(a1 + 13880);\n        *((_DWORD *)v19 + 469) = j;\n      }\n      ++*(_DWORD *)(a1 + 13880);\n      ++v14;\n      result = cocos2d::CCArray::count(v13);\n    }\n    while ( v14 < result );\n  }\n  return result;\n}", "assembly": "; \n; GJBaseGameLayer::refreshKeyframeAnims from 0x14033c9b0 to 0x14033cb8f (479 bytes)\n; \n; 3 xrefs:\n; > GJBaseGameLayer::updateSpecialGroupData @ 0x140314100\n; > LevelEditorLayer::init @ 0x1403eee12\n; > <???> @ 0x14091fc04\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:30:37 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x14033c9b0\nmov     [rsp+arg_8], rbp                                               ; +0x5, 0x14033c9b5\nmov     [rsp+arg_10], rsi                                              ; +0xa, 0x14033c9ba\npush    rdi                                                            ; +0xf, 0x14033c9bf\npush    r14                                                            ; +0x10, 0x14033c9c0\npush    r15                                                            ; +0x12, 0x14033c9c2\nsub     rsp, 20h                                                       ; +0x14, 0x14033c9c4\nmov     rsi, rcx                                                       ; +0x18, 0x14033c9c8\nmov     rcx, [rcx+3630h]                                               ; +0x1b, 0x14033c9cb\ncall    cs:?removeAllObjects@CCDictionary@cocos2d@@QEAAXXZ; cocos2d::CCDictionary::removeAllObjects(void) ; +0x22, 0x14033c9d2\nmov     dword ptr [rsi+3638h], 0                                       ; +0x28, 0x14033c9d8\ncall    cs:?create@CCDictionary@cocos2d@@SAPEAV12@XZ; cocos2d::CCDictionary::create(void) ; +0x32, 0x14033c9e2\nmov     r14, [rsi+0DD0h]                                               ; +0x38, 0x14033c9e8\nmov     r15, rax                                                       ; +0x3f, 0x14033c9ef\ntest    r14, r14                                                       ; +0x42, 0x14033c9f2\njz      loc_14033CA83                                                  ; +0x45, 0x14033c9f5\nmov     r14, [r14+38h]                                                 ; +0x4b, 0x14033c9fb\nmov     eax, [r14]                                                     ; +0x4f, 0x14033c9ff\ntest    eax, eax                                                       ; +0x52, 0x14033ca02\njz      short loc_14033CA83                                            ; +0x54, 0x14033ca04\nmov     r14, [r14+10h]                                                 ; +0x56, 0x14033ca06\nlea     rbp, [rax-1]                                                   ; +0x5a, 0x14033ca0a\nlea     rbp, [r14+rbp*8]                                               ; +0x5e, 0x14033ca0e\ncmp     r14, rbp                                                       ; +0x62, 0x14033ca12\nja      short loc_14033CA83                                            ; +0x65, 0x14033ca15\nmov     rbx, [r14]                                                     ; +0x67, 0x14033ca17\ntest    rbx, rbx                                                       ; +0x6a, 0x14033ca1a\njz      short loc_14033CA83                                            ; +0x6d, 0x14033ca1d\ncmp     dword ptr [rbx+40Ch], 0BD8h                                    ; +0x6f, 0x14033ca1f\njnz     short loc_14033CA7A                                            ; +0x79, 0x14033ca29\nmovsxd  rdx, dword ptr [rbx+750h]                                      ; +0x7b, 0x14033ca2b\nmov     rcx, r15                                                       ; +0x82, 0x14033ca32\ncall    cs:?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::objectForKey(__int64) ; +0x85, 0x14033ca35\nmov     rdi, rax                                                       ; +0x8b, 0x14033ca3b\ntest    rax, rax                                                       ; +0x8e, 0x14033ca3e\njnz     short loc_14033CA6E                                            ; +0x91, 0x14033ca41\ncall    cs:?create@CCArray@cocos2d@@SAPEAV12@XZ; cocos2d::CCArray::create(void) ; +0x93, 0x14033ca43\nmov     edx, [rbx+750h]                                                ; +0x99, 0x14033ca49\nmov     rdi, rax                                                       ; +0x9f, 0x14033ca4f\nmov     rcx, rdi                                                       ; +0xa2, 0x14033ca52\nmov     rax, [rax]                                                     ; +0xa5, 0x14033ca55\ncall    qword ptr [rax+40h]                                            ; +0xa8, 0x14033ca58\nmovsxd  r8, dword ptr [rbx+750h]                                       ; +0xab, 0x14033ca5b\nmov     rdx, rdi                                                       ; +0xb2, 0x14033ca62\nmov     rcx, r15                                                       ; +0xb5, 0x14033ca65\ncall    cs:?setObject@CCDictionary@cocos2d@@QEAAXPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::setObject(cocos2d::CCObject *,__int64) ; +0xb8, 0x14033ca68\nmov     rdx, rbx                                                       ; +0xbe, 0x14033ca6e\nmov     rcx, rdi                                                       ; +0xc1, 0x14033ca71\ncall    cs:?addObject@CCArray@cocos2d@@QEAAXPEAVCCObject@2@@Z; cocos2d::CCArray::addObject(cocos2d::CCObject *) ; +0xc4, 0x14033ca74\nadd     r14, 8                                                         ; +0xca, 0x14033ca7a\ncmp     r14, rbp                                                       ; +0xce, 0x14033ca7e\njbe     short loc_14033CA17                                            ; +0xd1, 0x14033ca81\nmov     rcx, r15                                                       ; +0xd3, 0x14033ca83\ncall    cs:?allKeys@CCDictionary@cocos2d@@QEAAPEAVCCArray@2@XZ; cocos2d::CCDictionary::allKeys(void) ; +0xd6, 0x14033ca86\nlea     r9, sub_14030B1D0; CompareFunction                             ; +0xdc, 0x14033ca8c\nmov     r8d, 8; SizeOfElements                                         ; +0xe3, 0x14033ca93\nmov     r14, rax                                                       ; +0xe9, 0x14033ca99\nmov     rcx, [rax+38h]                                                 ; +0xec, 0x14033ca9c\nmov     edx, [rcx]; NumOfElements                                      ; +0xf0, 0x14033caa0\nmov     rcx, [rcx+10h]; Base                                           ; +0xf2, 0x14033caa2\ncall    cs:qsort                                                       ; +0xf6, 0x14033caa6\nmov     rcx, r14                                                       ; +0xfc, 0x14033caac\nxor     ebp, ebp                                                       ; +0xff, 0x14033caaf\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x101, 0x14033cab1\ntest    eax, eax                                                       ; +0x107, 0x14033cab7\njz      loc_14033CB76                                                  ; +0x109, 0x14033cab9\nnop                                                                    ; +0x10f, 0x14033cabf\nmov     edx, ebp                                                       ; +0x110, 0x14033cac0\nmov     rcx, r14                                                       ; +0x112, 0x14033cac2\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x115, 0x14033cac5\nmov     rcx, r15                                                       ; +0x11b, 0x14033cacb\nmovsxd  rdx, dword ptr [rax+38h]                                       ; +0x11e, 0x14033cace\ncall    cs:?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::objectForKey(__int64) ; +0x122, 0x14033cad2\nlea     r9, sub_14030B1B0; CompareFunction                             ; +0x128, 0x14033cad8\nmov     r8d, 8; SizeOfElements                                         ; +0x12f, 0x14033cadf\nmov     rdi, rax                                                       ; +0x135, 0x14033cae5\nmov     rcx, [rax+38h]                                                 ; +0x138, 0x14033cae8\nmov     edx, [rcx]; NumOfElements                                      ; +0x13c, 0x14033caec\nmov     rcx, [rcx+10h]; Base                                           ; +0x13e, 0x14033caee\ncall    cs:qsort                                                       ; +0x142, 0x14033caf2\nmov     rcx, [rdi]                                                     ; +0x148, 0x14033caf8\nmov     edx, [rsi+3638h]                                               ; +0x14b, 0x14033cafb\nmov     r8, [rcx+40h]                                                  ; +0x151, 0x14033cb01\nmov     rcx, rdi                                                       ; +0x155, 0x14033cb05\ncall    r8                                                             ; +0x158, 0x14033cb08\nmovsxd  r8, dword ptr [rsi+3638h]                                      ; +0x15b, 0x14033cb0b\nmov     rdx, rdi                                                       ; +0x162, 0x14033cb12\nmov     rcx, [rsi+3630h]                                               ; +0x165, 0x14033cb15\ncall    cs:?setObject@CCDictionary@cocos2d@@QEAAXPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::setObject(cocos2d::CCObject *,__int64) ; +0x16c, 0x14033cb1c\nmov     rcx, rdi                                                       ; +0x172, 0x14033cb22\nxor     ebx, ebx                                                       ; +0x175, 0x14033cb25\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x177, 0x14033cb27\ntest    eax, eax                                                       ; +0x17d, 0x14033cb2d\njz      short loc_14033CB5D                                            ; +0x17f, 0x14033cb2f\nmov     edx, ebx                                                       ; +0x181, 0x14033cb31\nmov     rcx, rdi                                                       ; +0x183, 0x14033cb33\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x186, 0x14033cb36\nmov     ecx, [rsi+3638h]                                               ; +0x18c, 0x14033cb3c\nmov     [rax+750h], ecx                                                ; +0x192, 0x14033cb42\nmov     rcx, rdi                                                       ; +0x198, 0x14033cb48\nmov     [rax+754h], ebx                                                ; +0x19b, 0x14033cb4b\ninc     ebx                                                            ; +0x1a1, 0x14033cb51\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x1a3, 0x14033cb53\ncmp     ebx, eax                                                       ; +0x1a9, 0x14033cb59\njb      short loc_14033CB31                                            ; +0x1ab, 0x14033cb5b\ninc     dword ptr [rsi+3638h]                                          ; +0x1ad, 0x14033cb5d\nmov     rcx, r14                                                       ; +0x1b3, 0x14033cb63\ninc     ebp                                                            ; +0x1b6, 0x14033cb66\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x1b8, 0x14033cb68\ncmp     ebp, eax                                                       ; +0x1be, 0x14033cb6e\njb      loc_14033CAC0                                                  ; +0x1c0, 0x14033cb70\nmov     rbx, [rsp+38h+arg_0]                                           ; +0x1c6, 0x14033cb76\nmov     rbp, [rsp+38h+arg_8]                                           ; +0x1cb, 0x14033cb7b\nmov     rsi, [rsp+38h+arg_10]                                          ; +0x1d0, 0x14033cb80\nadd     rsp, 20h                                                       ; +0x1d5, 0x14033cb85\npop     r15                                                            ; +0x1d9, 0x14033cb89\npop     r14                                                            ; +0x1db, 0x14033cb8b\npop     rdi                                                            ; +0x1dd, 0x14033cb8d\nretn                                                                   ; +0x1de, 0x14033cb8e", "xrefs": ["GJBaseGameLayer::updateSpecialGroupData @ 0x140314100", "LevelEditorLayer::init @ 0x1403eee12", "<???> @ 0x14091fc04"], "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"}