{"type": "func", "start": 5372270144, "end": 5372270418, "name": "GJEffectManager::processColors", "pseudocode": "// \n// GJEffectManager::processColors from 0x140365640 to 0x140365752 (274 bytes)\n// \n// 9 xrefs:\n// > GJBaseGameLayer::loadUpToPosition @ 0x14033e9b3\n// > LevelEditorLayer::updateGameObjects @ 0x1403fb118\n// > LevelEditorLayer::updateGameObjects @ 0x1403fb5c6\n// > LevelEditorLayer::onPlaytest @ 0x1403fea52\n// > LevelEditorLayer::postUpdate @ 0x1404008ed\n// > PlayLayer::updateVisibility @ 0x14050df39\n// > <???> @ 0x1408baa58\n// > <???> @ 0x1408baa68\n// > <???> @ 0x140921608\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:54 +0000\n// \n\n__int64 __fastcall GJEffectManager::processColors(__int64 a1)\n{\n  __int64 v2; // r8\n  int v3; // ebp\n  __int64 v4; // r14\n  __int64 v5; // rsi\n  __int64 ColorAction; // rax\n  __int64 v7; // rbx\n  __int64 v8; // rax\n  char v10; // [rsp+40h] [rbp+8h] BYREF\n\n  GJEffectManager::calculateBaseActiveColors();\n  v2 = *(_QWORD *)(a1 + 344);\n  v3 = 0;\n  if ( (*(_QWORD *)(a1 + 352) - v2) / 72 )\n  {\n    v4 = 0;\n    do\n    {\n      v5 = v4 + v2;\n      ColorAction = GJEffectManager::getColorAction(a1, *(unsigned int *)(v4 + v2 + 20));\n      if ( !*(_DWORD *)(v5 + 52) && (!ColorAction || !*(_DWORD *)(ColorAction + 120)) )\n      {\n        v7 = *(_QWORD *)(ColorAction + 144);\n        v8 = GJEffectManager::colorForPulseEffect(a1, &v10, v7 + 327, v5);\n        *(_WORD *)(v7 + 327) = *(_WORD *)v8;\n        *(_BYTE *)(v7 + 329) = *(_BYTE *)(v8 + 2);\n      }\n      v2 = *(_QWORD *)(a1 + 344);\n      ++v3;\n      v4 += 72;\n    }\n    while ( v3 < (unsigned __int64)((*(_QWORD *)(a1 + 352) - v2) / 72) );\n  }\n  GJEffectManager::processInheritedColors(a1);\n  return GJEffectManager::processCopyColorPulseActions(a1);\n}", "assembly": "; \n; GJEffectManager::processColors from 0x140365640 to 0x140365752 (274 bytes)\n; \n; 9 xrefs:\n; > GJBaseGameLayer::loadUpToPosition @ 0x14033e9b3\n; > LevelEditorLayer::updateGameObjects @ 0x1403fb118\n; > LevelEditorLayer::updateGameObjects @ 0x1403fb5c6\n; > LevelEditorLayer::onPlaytest @ 0x1403fea52\n; > LevelEditorLayer::postUpdate @ 0x1404008ed\n; > PlayLayer::updateVisibility @ 0x14050df39\n; > <???> @ 0x1408baa58\n; > <???> @ 0x1408baa68\n; > <???> @ 0x140921608\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:54 +0000\n; \npush    rbp                                                            ; +0x0, 0x140365640\npush    rdi                                                            ; +0x2, 0x140365642\npush    r15                                                            ; +0x3, 0x140365643\nsub     rsp, 20h                                                       ; +0x5, 0x140365645\nmov     rdi, rcx                                                       ; +0x9, 0x140365649\ncall    GJEffectManager__calculateBaseActiveColors                     ; +0xc, 0x14036564c\nmov     r8, [rdi+158h]                                                 ; +0x11, 0x140365651\nmov     r15, 0E38E38E38E38E39h                                         ; +0x18, 0x140365658\nmov     rdx, [rdi+160h]                                                ; +0x22, 0x140365662\nmov     rax, r15                                                       ; +0x29, 0x140365669\nsub     rdx, r8                                                        ; +0x2c, 0x14036566c\nxor     ebp, ebp                                                       ; +0x2f, 0x14036566f\nimul    rdx                                                            ; +0x31, 0x140365671\nsar     rdx, 2                                                         ; +0x34, 0x140365674\nmov     rax, rdx                                                       ; +0x38, 0x140365678\nshr     rax, 3Fh                                                       ; +0x3b, 0x14036567b\nadd     rdx, rax                                                       ; +0x3f, 0x14036567f\njz      loc_14036573A                                                  ; +0x42, 0x140365682\nmov     [rsp+38h+arg_10], rsi                                          ; +0x48, 0x140365688\nmov     [rsp+38h+arg_18], r14                                          ; +0x4d, 0x14036568d\nmov     r14d, ebp                                                      ; +0x52, 0x140365692\nmov     [rsp+38h+arg_8], rbx                                           ; +0x55, 0x140365695\nnop     word ptr [rax+rax+00h]                                         ; +0x5a, 0x14036569a\nmov     edx, [r14+r8+14h]                                              ; +0x60, 0x1403656a0\nlea     rsi, [r14+r8]                                                  ; +0x65, 0x1403656a5\nmov     rcx, rdi                                                       ; +0x69, 0x1403656a9\ncall    GJEffectManager__getColorAction                                ; +0x6c, 0x1403656ac\ncmp     dword ptr [rsi+34h], 0                                         ; +0x71, 0x1403656b1\njnz     short loc_1403656F4                                            ; +0x75, 0x1403656b5\ntest    rax, rax                                                       ; +0x77, 0x1403656b7\njz      short loc_1403656C2                                            ; +0x7a, 0x1403656ba\ncmp     dword ptr [rax+78h], 0                                         ; +0x7c, 0x1403656bc\njnz     short loc_1403656F4                                            ; +0x80, 0x1403656c0\nmov     rbx, [rax+90h]                                                 ; +0x82, 0x1403656c2\nlea     rdx, [rsp+38h+arg_0]                                           ; +0x89, 0x1403656c9\nmov     r9, rsi                                                        ; +0x8e, 0x1403656ce\nmov     rcx, rdi                                                       ; +0x91, 0x1403656d1\nlea     r8, [rbx+147h]                                                 ; +0x94, 0x1403656d4\ncall    GJEffectManager__colorForPulseEffect                           ; +0x9b, 0x1403656db\nmovzx   ecx, word ptr [rax]                                            ; +0xa0, 0x1403656e0\nmov     [rbx+147h], cx                                                 ; +0xa3, 0x1403656e3\nmovzx   eax, byte ptr [rax+2]                                          ; +0xaa, 0x1403656ea\nmov     [rbx+149h], al                                                 ; +0xae, 0x1403656ee\nmov     r8, [rdi+158h]                                                 ; +0xb4, 0x1403656f4\ninc     ebp                                                            ; +0xbb, 0x1403656fb\nmov     rcx, [rdi+160h]                                                ; +0xbd, 0x1403656fd\nmov     rax, r15                                                       ; +0xc4, 0x140365704\nsub     rcx, r8                                                        ; +0xc7, 0x140365707\nadd     r14, 48h ; 'H'                                                 ; +0xca, 0x14036570a\nimul    rcx                                                            ; +0xce, 0x14036570e\nsar     rdx, 2                                                         ; +0xd1, 0x140365711\nmov     rax, rdx                                                       ; +0xd5, 0x140365715\nshr     rax, 3Fh                                                       ; +0xd8, 0x140365718\nadd     rdx, rax                                                       ; +0xdc, 0x14036571c\nmovsxd  rax, ebp                                                       ; +0xdf, 0x14036571f\ncmp     rax, rdx                                                       ; +0xe2, 0x140365722\njb      loc_1403656A0                                                  ; +0xe5, 0x140365725\nmov     r14, [rsp+38h+arg_18]                                          ; +0xeb, 0x14036572b\nmov     rsi, [rsp+38h+arg_10]                                          ; +0xf0, 0x140365730\nmov     rbx, [rsp+38h+arg_8]                                           ; +0xf5, 0x140365735\nmov     rcx, rdi                                                       ; +0xfa, 0x14036573a\ncall    GJEffectManager__processInheritedColors                        ; +0xfd, 0x14036573d\nmov     rcx, rdi                                                       ; +0x102, 0x140365742\nadd     rsp, 20h                                                       ; +0x105, 0x140365745\npop     r15                                                            ; +0x109, 0x140365749\npop     rdi                                                            ; +0x10b, 0x14036574b\npop     rbp                                                            ; +0x10c, 0x14036574c\njmp     GJEffectManager__processCopyColorPulseActions                  ; +0x10d, 0x14036574d", "xrefs": ["GJBaseGameLayer::loadUpToPosition @ 0x14033e9b3", "LevelEditorLayer::updateGameObjects @ 0x1403fb118", "LevelEditorLayer::updateGameObjects @ 0x1403fb5c6", "LevelEditorLayer::onPlaytest @ 0x1403fea52", "LevelEditorLayer::postUpdate @ 0x1404008ed", "PlayLayer::updateVisibility @ 0x14050df39", "<???> @ 0x1408baa58", "<???> @ 0x1408baa68", "<???> @ 0x140921608"], "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"}