{"type": "func", "start": 4295952544, "end": 4295953228, "name": "GJBaseGameLayer::updateLevelColors", "pseudocode": "// \n// GJBaseGameLayer::updateLevelColors from 0x1000f08a0 to 0x1000f0b4c (684 bytes)\n// \n// 12 xrefs:\n// > PlayLayer::setupHasCompleted @ 0x10007bb97\n// > PlayLayer::setupHasCompleted @ 0x10007becd\n// > PlayLayer::postUpdate @ 0x100088b91\n// > PlayLayer::resetLevel @ 0x10008d061\n// > LevelEditorLayer::updateGameObjects @ 0x1000ad874\n// > LevelEditorLayer::onPlaytest @ 0x1000c6136\n// > LevelEditorLayer::postUpdate @ 0x1000c7446\n// > GJBaseGameLayer::swapBackground @ 0x1000f085e\n// > GJBaseGameLayer::asyncBGLoaded @ 0x1000f0897\n// > GJBaseGameLayer::asyncGLoaded @ 0x1000f0ba9\n// > GJBaseGameLayer::swapMiddleground @ 0x1000f0d77\n// > GJBaseGameLayer::asyncMGLoaded @ 0x1000f0ee7\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:21:11 +0000\n// \n\n__int64 __fastcall GJBaseGameLayer::updateLevelColors(__int64 a1, double a2)\n{\n  int active; // eax\n  unsigned int v3; // r14d\n  unsigned int v4; // r14d\n  __int64 v5; // rax\n  __int64 v6; // r14\n  unsigned __int8 shouldBlend; // al\n  __int64 v8; // r14\n  unsigned __int8 v9; // al\n  __int64 result; // rax\n  __int64 v11; // r14\n  unsigned int v12; // eax\n  __int64 v13; // r14\n  unsigned int v14; // eax\n  __int64 v15; // r14\n  float v16; // xmm0_4\n  double updated; // xmm0_8\n  __int64 v18; // r14\n  double v19; // xmm0_8\n  __int64 v20; // r14\n  unsigned __int8 v21; // al\n  __int64 v22; // r14\n  unsigned __int8 v23; // al\n  __int16 v24; // [rsp+8h] [rbp-18h] BYREF\n  char v25; // [rsp+Ah] [rbp-16h]\n  __int16 v26; // [rsp+Ch] [rbp-14h] BYREF\n  char v27; // [rsp+Eh] [rbp-12h]\n\n  active = GJEffectManager::activeColorForIndex(*(_QWORD *)(a1 + 2152), 1000);\n  v24 = active;\n  v25 = BYTE2(active);\n  (*(void (__fastcall **)(_QWORD, __int16 *))(**(_QWORD **)(a1 + 3944) + 960LL))(*(_QWORD *)(a1 + 3944), &v24);\n  v3 = GJEffectManager::activeColorForIndex(*(_QWORD *)(a1 + 2152), 1001);\n  GJGroundLayer::updateGround01Color(*(_QWORD *)(a1 + 3960), v3);\n  GJGroundLayer::updateGround01Color(*(_QWORD *)(a1 + 3968), v3);\n  if ( *(_QWORD *)(*(_QWORD *)(a1 + 3960) + 416LL) )\n  {\n    v4 = GJEffectManager::activeColorForIndex(*(_QWORD *)(a1 + 2152), 1009);\n    GJGroundLayer::updateGround02Color(*(_QWORD *)(a1 + 3960), v4);\n    GJGroundLayer::updateGround02Color(*(_QWORD *)(a1 + 3968), v4);\n  }\n  v5 = GJEffectManager::activeColorForIndex(*(_QWORD *)(a1 + 2152), 1002);\n  v26 = v5;\n  v27 = BYTE2(v5);\n  *(float *)&a2 = GJEffectManager::activeOpacityForIndex(*(_QWORD *)(a1 + 2152), 1002, a2) * 255.0;\n  (*(void (__fastcall **)(_QWORD, __int16 *))(**(_QWORD **)(*(_QWORD *)(a1 + 3960) + 432LL) + 960LL))(\n    *(_QWORD *)(*(_QWORD *)(a1 + 3960) + 432LL),\n    &v26);\n  (*(void (__fastcall **)(_QWORD, __int16 *))(**(_QWORD **)(*(_QWORD *)(a1 + 3968) + 432LL) + 960LL))(\n    *(_QWORD *)(*(_QWORD *)(a1 + 3968) + 432LL),\n    &v26);\n  (*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(*(_QWORD *)(a1 + 3960) + 432LL) + 912LL))(\n    *(_QWORD *)(*(_QWORD *)(a1 + 3960) + 432LL),\n    (unsigned __int8)(int)*(float *)&a2);\n  (*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(*(_QWORD *)(a1 + 3968) + 432LL) + 912LL))(\n    *(_QWORD *)(*(_QWORD *)(a1 + 3968) + 432LL),\n    (unsigned __int8)(int)*(float *)&a2);\n  v6 = *(_QWORD *)(a1 + 3960);\n  shouldBlend = GJEffectManager::shouldBlend(*(_QWORD *)(a1 + 2152));\n  GJGroundLayer::updateLineBlend(v6, shouldBlend);\n  v8 = *(_QWORD *)(a1 + 3968);\n  v9 = GJEffectManager::shouldBlend(*(_QWORD *)(a1 + 2152));\n  result = GJGroundLayer::updateLineBlend(v8, v9);\n  v11 = *(_QWORD *)(a1 + 3976);\n  if ( v11 )\n  {\n    v12 = GJEffectManager::activeColorForIndex(*(_QWORD *)(a1 + 2152), 1013);\n    GJMGLayer::updateGroundColor(v11, v12, 1);\n    v13 = *(_QWORD *)(a1 + 3976);\n    v14 = GJEffectManager::activeColorForIndex(*(_QWORD *)(a1 + 2152), 1014);\n    GJMGLayer::updateGroundColor(v13, v14, 0);\n    v15 = *(_QWORD *)(a1 + 3976);\n    v16 = GJEffectManager::activeOpacityForIndex(*(_QWORD *)(a1 + 2152), 1013, a2);\n    updated = GJMGLayer::updateGroundOpacity(v15, (unsigned __int8)(int)(float)(v16 * 255.0), 1);\n    v18 = *(_QWORD *)(a1 + 3976);\n    *(float *)&updated = GJEffectManager::activeOpacityForIndex(*(_QWORD *)(a1 + 2152), 1014, updated);\n    v19 = GJMGLayer::updateGroundOpacity(v18, (unsigned __int8)(int)(float)(*(float *)&updated * 255.0), 0);\n    v20 = *(_QWORD *)(a1 + 3976);\n    v21 = GJEffectManager::shouldBlend(*(_QWORD *)(a1 + 2152));\n    GJMGLayer::updateMG01Blend(v20, v21, v19);\n    v22 = *(_QWORD *)(a1 + 3976);\n    v23 = GJEffectManager::shouldBlend(*(_QWORD *)(a1 + 2152));\n    return GJMGLayer::updateMG02Blend(v22, v23);\n  }\n  return result;\n}", "assembly": "; \n; GJBaseGameLayer::updateLevelColors from 0x1000f08a0 to 0x1000f0b4c (684 bytes)\n; \n; 12 xrefs:\n; > PlayLayer::setupHasCompleted @ 0x10007bb97\n; > PlayLayer::setupHasCompleted @ 0x10007becd\n; > PlayLayer::postUpdate @ 0x100088b91\n; > PlayLayer::resetLevel @ 0x10008d061\n; > LevelEditorLayer::updateGameObjects @ 0x1000ad874\n; > LevelEditorLayer::onPlaytest @ 0x1000c6136\n; > LevelEditorLayer::postUpdate @ 0x1000c7446\n; > GJBaseGameLayer::swapBackground @ 0x1000f085e\n; > GJBaseGameLayer::asyncBGLoaded @ 0x1000f0897\n; > GJBaseGameLayer::asyncGLoaded @ 0x1000f0ba9\n; > GJBaseGameLayer::swapMiddleground @ 0x1000f0d77\n; > GJBaseGameLayer::asyncMGLoaded @ 0x1000f0ee7\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:21:11 +0000\n; \npush    rbp                                                            ; +0x0, 0x1000f08a0\nmov     rbp, rsp                                                       ; +0x1, 0x1000f08a1\npush    r14                                                            ; +0x4, 0x1000f08a4\npush    rbx                                                            ; +0x6, 0x1000f08a6\nsub     rsp, 10h                                                       ; +0x7, 0x1000f08a7\nmov     rbx, rdi                                                       ; +0xb, 0x1000f08ab\nmov     rdi, [rdi+868h]                                                ; +0xe, 0x1000f08ae\nmov     esi, 3E8h                                                      ; +0x15, 0x1000f08b5\ncall    GJEffectManager__activeColorForIndex                           ; +0x1a, 0x1000f08ba\nmov     [rbp+var_18], ax                                               ; +0x1f, 0x1000f08bf\nshr     eax, 10h                                                       ; +0x23, 0x1000f08c3\nmov     [rbp+var_16], al                                               ; +0x26, 0x1000f08c6\nmov     rdi, [rbx+0F68h]                                               ; +0x29, 0x1000f08c9\nmov     rax, [rdi]                                                     ; +0x30, 0x1000f08d0\nlea     rsi, [rbp+var_18]                                              ; +0x33, 0x1000f08d3\ncall    qword ptr [rax+3C0h]                                           ; +0x37, 0x1000f08d7\nmov     rdi, [rbx+868h]                                                ; +0x3d, 0x1000f08dd\nmov     esi, 3E9h                                                      ; +0x44, 0x1000f08e4\ncall    GJEffectManager__activeColorForIndex                           ; +0x49, 0x1000f08e9\nmov     r14d, eax                                                      ; +0x4e, 0x1000f08ee\nmov     rdi, [rbx+0F78h]                                               ; +0x51, 0x1000f08f1\nmov     esi, eax                                                       ; +0x58, 0x1000f08f8\ncall    GJGroundLayer__updateGround01Color                             ; +0x5a, 0x1000f08fa\nmov     rdi, [rbx+0F80h]                                               ; +0x5f, 0x1000f08ff\nmov     esi, r14d                                                      ; +0x66, 0x1000f0906\ncall    GJGroundLayer__updateGround01Color                             ; +0x69, 0x1000f0909\nmov     rax, [rbx+0F78h]                                               ; +0x6e, 0x1000f090e\ncmp     qword ptr [rax+1A0h], 0                                        ; +0x75, 0x1000f0915\njz      short loc_1000F0950                                            ; +0x7d, 0x1000f091d\nmov     rdi, [rbx+868h]                                                ; +0x7f, 0x1000f091f\nmov     esi, 3F1h                                                      ; +0x86, 0x1000f0926\ncall    GJEffectManager__activeColorForIndex                           ; +0x8b, 0x1000f092b\nmov     r14d, eax                                                      ; +0x90, 0x1000f0930\nmov     rdi, [rbx+0F78h]                                               ; +0x93, 0x1000f0933\nmov     esi, eax                                                       ; +0x9a, 0x1000f093a\ncall    GJGroundLayer__updateGround02Color                             ; +0x9c, 0x1000f093c\nmov     rdi, [rbx+0F80h]                                               ; +0xa1, 0x1000f0941\nmov     esi, r14d                                                      ; +0xa8, 0x1000f0948\ncall    GJGroundLayer__updateGround02Color                             ; +0xab, 0x1000f094b\nmov     rdi, [rbx+868h]                                                ; +0xb0, 0x1000f0950\nmov     esi, 3EAh                                                      ; +0xb7, 0x1000f0957\ncall    GJEffectManager__activeColorForIndex                           ; +0xbc, 0x1000f095c\nmov     [rbp+var_14], ax                                               ; +0xc1, 0x1000f0961\nshr     eax, 10h                                                       ; +0xc5, 0x1000f0965\nmov     [rbp+var_12], al                                               ; +0xc8, 0x1000f0968\nmov     rdi, [rbx+868h]                                                ; +0xcb, 0x1000f096b\nmov     esi, 3EAh                                                      ; +0xd2, 0x1000f0972\ncall    GJEffectManager__activeOpacityForIndex                         ; +0xd7, 0x1000f0977\nmulss   xmm0, cs:dword_100A03F80                                       ; +0xdc, 0x1000f097c\nmovss   [rbp+var_1C], xmm0                                             ; +0xe4, 0x1000f0984\nmov     rax, [rbx+0F78h]                                               ; +0xe9, 0x1000f0989\nmov     rdi, [rax+1B0h]                                                ; +0xf0, 0x1000f0990\nmov     rax, [rdi]                                                     ; +0xf7, 0x1000f0997\nlea     r14, [rbp+var_14]                                              ; +0xfa, 0x1000f099a\nmov     rsi, r14                                                       ; +0xfe, 0x1000f099e\ncall    qword ptr [rax+3C0h]                                           ; +0x101, 0x1000f09a1\nmov     rax, [rbx+0F80h]                                               ; +0x107, 0x1000f09a7\nmov     rdi, [rax+1B0h]                                                ; +0x10e, 0x1000f09ae\nmov     rax, [rdi]                                                     ; +0x115, 0x1000f09b5\nmov     rsi, r14                                                       ; +0x118, 0x1000f09b8\ncall    qword ptr [rax+3C0h]                                           ; +0x11b, 0x1000f09bb\nmov     rax, [rbx+0F78h]                                               ; +0x121, 0x1000f09c1\nmov     rdi, [rax+1B0h]                                                ; +0x128, 0x1000f09c8\ncvttss2si eax, [rbp+var_1C]                                            ; +0x12f, 0x1000f09cf\nmov     rcx, [rdi]                                                     ; +0x134, 0x1000f09d4\nmovzx   r14d, al                                                       ; +0x137, 0x1000f09d7\nmov     esi, r14d                                                      ; +0x13b, 0x1000f09db\ncall    qword ptr [rcx+390h]                                           ; +0x13e, 0x1000f09de\nmov     rax, [rbx+0F80h]                                               ; +0x144, 0x1000f09e4\nmov     rdi, [rax+1B0h]                                                ; +0x14b, 0x1000f09eb\nmov     rax, [rdi]                                                     ; +0x152, 0x1000f09f2\nmov     esi, r14d                                                      ; +0x155, 0x1000f09f5\ncall    qword ptr [rax+390h]                                           ; +0x158, 0x1000f09f8\nmov     r14, [rbx+0F78h]                                               ; +0x15e, 0x1000f09fe\nmov     rdi, [rbx+868h]                                                ; +0x165, 0x1000f0a05\nmov     esi, 3EAh                                                      ; +0x16c, 0x1000f0a0c\ncall    GJEffectManager__shouldBlend                                   ; +0x171, 0x1000f0a11\nmovzx   esi, al                                                        ; +0x176, 0x1000f0a16\nmov     rdi, r14                                                       ; +0x179, 0x1000f0a19\ncall    GJGroundLayer__updateLineBlend                                 ; +0x17c, 0x1000f0a1c\nmov     r14, [rbx+0F80h]                                               ; +0x181, 0x1000f0a21\nmov     rdi, [rbx+868h]                                                ; +0x188, 0x1000f0a28\nmov     esi, 3EAh                                                      ; +0x18f, 0x1000f0a2f\ncall    GJEffectManager__shouldBlend                                   ; +0x194, 0x1000f0a34\nmovzx   esi, al                                                        ; +0x199, 0x1000f0a39\nmov     rdi, r14                                                       ; +0x19c, 0x1000f0a3c\ncall    GJGroundLayer__updateLineBlend                                 ; +0x19f, 0x1000f0a3f\nmov     r14, [rbx+0F88h]                                               ; +0x1a4, 0x1000f0a44\ntest    r14, r14                                                       ; +0x1ab, 0x1000f0a4b\njz      loc_1000F0B43                                                  ; +0x1ae, 0x1000f0a4e\nmov     rdi, [rbx+868h]                                                ; +0x1b4, 0x1000f0a54\nmov     esi, 3F5h                                                      ; +0x1bb, 0x1000f0a5b\ncall    GJEffectManager__activeColorForIndex                           ; +0x1c0, 0x1000f0a60\nmov     rdi, r14                                                       ; +0x1c5, 0x1000f0a65\nmov     esi, eax                                                       ; +0x1c8, 0x1000f0a68\nmov     edx, 1                                                         ; +0x1ca, 0x1000f0a6a\ncall    GJMGLayer__updateGroundColor                                   ; +0x1cf, 0x1000f0a6f\nmov     r14, [rbx+0F88h]                                               ; +0x1d4, 0x1000f0a74\nmov     rdi, [rbx+868h]                                                ; +0x1db, 0x1000f0a7b\nmov     esi, 3F6h                                                      ; +0x1e2, 0x1000f0a82\ncall    GJEffectManager__activeColorForIndex                           ; +0x1e7, 0x1000f0a87\nmov     rdi, r14                                                       ; +0x1ec, 0x1000f0a8c\nmov     esi, eax                                                       ; +0x1ef, 0x1000f0a8f\nxor     edx, edx                                                       ; +0x1f1, 0x1000f0a91\ncall    GJMGLayer__updateGroundColor                                   ; +0x1f3, 0x1000f0a93\nmov     r14, [rbx+0F88h]                                               ; +0x1f8, 0x1000f0a98\nmov     rdi, [rbx+868h]                                                ; +0x1ff, 0x1000f0a9f\nmov     esi, 3F5h                                                      ; +0x206, 0x1000f0aa6\ncall    GJEffectManager__activeOpacityForIndex                         ; +0x20b, 0x1000f0aab\nmulss   xmm0, cs:dword_100A03F80                                       ; +0x210, 0x1000f0ab0\ncvttss2si eax, xmm0                                                    ; +0x218, 0x1000f0ab8\nmovzx   esi, al                                                        ; +0x21c, 0x1000f0abc\nmov     rdi, r14                                                       ; +0x21f, 0x1000f0abf\nmov     edx, 1                                                         ; +0x222, 0x1000f0ac2\ncall    GJMGLayer__updateGroundOpacity                                 ; +0x227, 0x1000f0ac7\nmov     r14, [rbx+0F88h]                                               ; +0x22c, 0x1000f0acc\nmov     rdi, [rbx+868h]                                                ; +0x233, 0x1000f0ad3\nmov     esi, 3F6h                                                      ; +0x23a, 0x1000f0ada\ncall    GJEffectManager__activeOpacityForIndex                         ; +0x23f, 0x1000f0adf\nmulss   xmm0, cs:dword_100A03F80                                       ; +0x244, 0x1000f0ae4\ncvttss2si eax, xmm0                                                    ; +0x24c, 0x1000f0aec\nmovzx   esi, al                                                        ; +0x250, 0x1000f0af0\nmov     rdi, r14                                                       ; +0x253, 0x1000f0af3\nxor     edx, edx                                                       ; +0x256, 0x1000f0af6\ncall    GJMGLayer__updateGroundOpacity                                 ; +0x258, 0x1000f0af8\nmov     r14, [rbx+0F88h]                                               ; +0x25d, 0x1000f0afd\nmov     rdi, [rbx+868h]                                                ; +0x264, 0x1000f0b04\nmov     esi, 3F5h                                                      ; +0x26b, 0x1000f0b0b\ncall    GJEffectManager__shouldBlend                                   ; +0x270, 0x1000f0b10\nmovzx   esi, al                                                        ; +0x275, 0x1000f0b15\nmov     rdi, r14                                                       ; +0x278, 0x1000f0b18\ncall    GJMGLayer__updateMG01Blend                                     ; +0x27b, 0x1000f0b1b\nmov     r14, [rbx+0F88h]                                               ; +0x280, 0x1000f0b20\nmov     rdi, [rbx+868h]                                                ; +0x287, 0x1000f0b27\nmov     esi, 3F6h                                                      ; +0x28e, 0x1000f0b2e\ncall    GJEffectManager__shouldBlend                                   ; +0x293, 0x1000f0b33\nmovzx   esi, al                                                        ; +0x298, 0x1000f0b38\nmov     rdi, r14                                                       ; +0x29b, 0x1000f0b3b\ncall    GJMGLayer__updateMG02Blend                                     ; +0x29e, 0x1000f0b3e\nadd     rsp, 10h                                                       ; +0x2a3, 0x1000f0b43\npop     rbx                                                            ; +0x2a7, 0x1000f0b47\npop     r14                                                            ; +0x2a8, 0x1000f0b48\npop     rbp                                                            ; +0x2aa, 0x1000f0b4a\nretn                                                                   ; +0x2ab, 0x1000f0b4b", "xrefs": ["PlayLayer::setupHasCompleted @ 0x10007bb97", "PlayLayer::setupHasCompleted @ 0x10007becd", "PlayLayer::postUpdate @ 0x100088b91", "PlayLayer::resetLevel @ 0x10008d061", "LevelEditorLayer::updateGameObjects @ 0x1000ad874", "LevelEditorLayer::onPlaytest @ 0x1000c6136", "LevelEditorLayer::postUpdate @ 0x1000c7446", "GJBaseGameLayer::swapBackground @ 0x1000f085e", "GJBaseGameLayer::asyncBGLoaded @ 0x1000f0897", "GJBaseGameLayer::asyncGLoaded @ 0x1000f0ba9", "GJBaseGameLayer::swapMiddleground @ 0x1000f0d77", "GJBaseGameLayer::asyncMGLoaded @ 0x1000f0ee7"], "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"}