{"type": "func", "start": 4298500368, "end": 4298500568, "name": "CCPartAnimSprite::setColor", "pseudocode": "// \n// CCPartAnimSprite::setColor from 0x10035e910 to 0x10035e9d8 (200 bytes)\n// \n// 4 xrefs:\n// > CCAnimatedSprite::switchToMode @ 0x10033c0a2\n// > CCAnimatedSprite::setColor @ 0x10033c7bd\n// > sub_10033C7E0 @ 0x10033c81d\n// > GJRobotSprite::updateColors @ 0x1006ae668\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:28:55 +0000\n// \n\n__int64 __fastcall CCPartAnimSprite::setColor(__int64 a1, int a2)\n{\n  __int64 v2; // rax\n  __int64 result; // rax\n  _QWORD *v4; // r14\n  __int64 v5; // r15\n  unsigned __int64 i; // r15\n  __int16 v7; // [rsp+0h] [rbp-1Ch] BYREF\n  char v8; // [rsp+2h] [rbp-1Ah]\n  char v9; // [rsp+3h] [rbp-19h]\n\n  v9 = HIBYTE(v2);\n  v7 = a2;\n  v8 = BYTE2(a2);\n  cocos2d::CCSprite::setColor(a1, (__int64)&v7);\n  result = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 488LL))(a1);\n  if ( result )\n  {\n    result = *(_QWORD *)((*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 488LL))(a1) + 56);\n    if ( *(_DWORD *)result )\n    {\n      v4 = *(_QWORD **)(*(_QWORD *)((*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 488LL))(a1) + 56) + 16LL);\n      v5 = *(_QWORD *)(*(_QWORD *)((*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 488LL))(a1) + 56) + 16LL);\n      result = **(unsigned int **)((*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 488LL))(a1) + 56);\n      for ( i = v5 + 8 * result - 8; (unsigned __int64)v4 <= i; ++v4 )\n      {\n        if ( !*v4 )\n          break;\n        result = (*(__int64 (__fastcall **)(_QWORD, __int16 *))(*(_QWORD *)*v4 + 960LL))(*v4, &v7);\n      }\n    }\n  }\n  return result;\n}", "assembly": "; \n; CCPartAnimSprite::setColor from 0x10035e910 to 0x10035e9d8 (200 bytes)\n; \n; 4 xrefs:\n; > CCAnimatedSprite::switchToMode @ 0x10033c0a2\n; > CCAnimatedSprite::setColor @ 0x10033c7bd\n; > sub_10033C7E0 @ 0x10033c81d\n; > GJRobotSprite::updateColors @ 0x1006ae668\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:28:55 +0000\n; \npush    rbp                                                            ; +0x0, 0x10035e910\nmov     rbp, rsp                                                       ; +0x1, 0x10035e911\npush    r15                                                            ; +0x4, 0x10035e914\npush    r14                                                            ; +0x6, 0x10035e916\npush    rbx                                                            ; +0x8, 0x10035e918\npush    rax                                                            ; +0x9, 0x10035e919\nmov     rbx, rdi                                                       ; +0xa, 0x10035e91a\nmov     [rbp+var_1C], si                                               ; +0xd, 0x10035e91d\nshr     esi, 10h                                                       ; +0x11, 0x10035e921\nmov     [rbp+var_1A], sil                                              ; +0x14, 0x10035e924\nlea     rsi, [rbp+var_1C]                                              ; +0x18, 0x10035e928\ncall    cocos2d__CCSprite__setColor                                    ; +0x1c, 0x10035e92c\nmov     rax, [rbx]                                                     ; +0x21, 0x10035e931\nmov     rdi, rbx                                                       ; +0x24, 0x10035e934\ncall    qword ptr [rax+1E8h]                                           ; +0x27, 0x10035e937\ntest    rax, rax                                                       ; +0x2d, 0x10035e93d\njz      loc_10035E9CD                                                  ; +0x30, 0x10035e940\nmov     rax, [rbx]                                                     ; +0x36, 0x10035e946\nmov     rdi, rbx                                                       ; +0x39, 0x10035e949\ncall    qword ptr [rax+1E8h]                                           ; +0x3c, 0x10035e94c\nmov     rax, [rax+38h]                                                 ; +0x42, 0x10035e952\ncmp     dword ptr [rax], 0                                             ; +0x46, 0x10035e956\njz      short loc_10035E9CD                                            ; +0x49, 0x10035e959\nmov     rax, [rbx]                                                     ; +0x4b, 0x10035e95b\nmov     rdi, rbx                                                       ; +0x4e, 0x10035e95e\ncall    qword ptr [rax+1E8h]                                           ; +0x51, 0x10035e961\nmov     rax, [rax+38h]                                                 ; +0x57, 0x10035e967\nmov     r14, [rax+10h]                                                 ; +0x5b, 0x10035e96b\nmov     rax, [rbx]                                                     ; +0x5f, 0x10035e96f\nmov     rdi, rbx                                                       ; +0x62, 0x10035e972\ncall    qword ptr [rax+1E8h]                                           ; +0x65, 0x10035e975\nmov     rax, [rax+38h]                                                 ; +0x6b, 0x10035e97b\nmov     r15, [rax+10h]                                                 ; +0x6f, 0x10035e97f\nmov     rax, [rbx]                                                     ; +0x73, 0x10035e983\nmov     rdi, rbx                                                       ; +0x76, 0x10035e986\ncall    qword ptr [rax+1E8h]                                           ; +0x79, 0x10035e989\nmov     rax, [rax+38h]                                                 ; +0x7f, 0x10035e98f\nmov     eax, [rax]                                                     ; +0x83, 0x10035e993\nlea     r15, [r15+rax*8]                                               ; +0x85, 0x10035e995\nadd     r15, 0FFFFFFFFFFFFFFF8h                                        ; +0x89, 0x10035e999\ncmp     r14, r15                                                       ; +0x8d, 0x10035e99d\nja      short loc_10035E9CD                                            ; +0x90, 0x10035e9a0\nlea     rbx, [rbp+var_1C]                                              ; +0x92, 0x10035e9a2\nnop     word ptr [rax+rax+00000000h]                                   ; +0x96, 0x10035e9a6\nmov     rdi, [r14]                                                     ; +0xa0, 0x10035e9b0\ntest    rdi, rdi                                                       ; +0xa3, 0x10035e9b3\njz      short loc_10035E9CD                                            ; +0xa6, 0x10035e9b6\nmov     rax, [rdi]                                                     ; +0xa8, 0x10035e9b8\nmov     rsi, rbx                                                       ; +0xab, 0x10035e9bb\ncall    qword ptr [rax+3C0h]                                           ; +0xae, 0x10035e9be\nadd     r14, 8                                                         ; +0xb4, 0x10035e9c4\ncmp     r14, r15                                                       ; +0xb8, 0x10035e9c8\njbe     short loc_10035E9B0                                            ; +0xbb, 0x10035e9cb\nadd     rsp, 8                                                         ; +0xbd, 0x10035e9cd\npop     rbx                                                            ; +0xc1, 0x10035e9d1\npop     r14                                                            ; +0xc2, 0x10035e9d2\npop     r15                                                            ; +0xc4, 0x10035e9d4\npop     rbp                                                            ; +0xc6, 0x10035e9d6\nretn                                                                   ; +0xc7, 0x10035e9d7", "xrefs": ["CCAnimatedSprite::switchToMode @ 0x10033c0a2", "CCAnimatedSprite::setColor @ 0x10033c7bd", "sub_10033C7E0 @ 0x10033c81d", "GJRobotSprite::updateColors @ 0x1006ae668"], "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"}