{"type": "func", "start": 7937984, "end": 7938344, "name": "GJGarageLayer::updatePlayerColors", "pseudocode": "// \n// GJGarageLayer::updatePlayerColors from 0x791fc0 to 0x792128 (360 bytes)\n// \n// 3 xrefs:\n// > GJGarageLayer::playerColorChanged @ 0x79215c\n// > GJGarageLayer::init @ 0x7995ac\n// > <???> @ 0x9e0a0\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nvoid GJGarageLayer::updatePlayerColors(GJGarageLayer *a1)\n{\n  SimplePlayer *m_playerObject; // x22\n  SimplePlayer *v3; // x22\n  GameManager *v4; // x23\n  GameManager *v5; // x0\n  GameManager *v6; // x23\n  GameManager *v7; // x0\n  GameManager *v8; // x0\n  SimplePlayer *v9; // x22\n  GameManager *v10; // x23\n  GameManager *v11; // x0\n  cocos2d::ccColor3B v12; // [xsp+48h] [xbp+48h] BYREF\n  cocos2d::ccColor3B v13; // [xsp+50h] [xbp+50h] BYREF\n\n  m_playerObject = a1->m_playerObject;\n  m_playerObject->m_hasGlowOutline = GameManager::sharedState()->m_playerGlow;\n  v3 = a1->m_playerObject;\n  v4 = GameManager::sharedState();\n  v5 = GameManager::sharedState();\n  v12 = GameManager::colorForIdx(v4, v5->m_playerColor.random - v5->m_playerColor.seed);\n  v6 = GameManager::sharedState();\n  v7 = GameManager::sharedState();\n  v13 = GameManager::colorForIdx(v6, v7->m_playerColor2.random - v7->m_playerColor2.seed);\n  SimplePlayer::setColors(v3, &v12, &v13);\n  v8 = GameManager::sharedState();\n  if ( v8->m_playerGlowColor.random - v8->m_playerGlowColor.seed < 0 )\n  {\n    SimplePlayer::disableCustomGlowColor(a1->m_playerObject);\n  }\n  else\n  {\n    v9 = a1->m_playerObject;\n    v10 = GameManager::sharedState();\n    v11 = GameManager::sharedState();\n    v13 = GameManager::colorForIdx(v10, v11->m_playerGlowColor.random - v11->m_playerGlowColor.seed);\n    SimplePlayer::enableCustomGlowColor(v9, &v13);\n  }\n  SimplePlayer::updateColors(a1->m_playerObject);\n}", "assembly": "; \n; GJGarageLayer::updatePlayerColors from 0x791fc0 to 0x792128 (360 bytes)\n; \n; 3 xrefs:\n; > GJGarageLayer::playerColorChanged @ 0x79215c\n; > GJGarageLayer::init @ 0x7995ac\n; > <???> @ 0x9e0a0\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nSTP             X29, X30, [SP,#var_60]!                                ; +0x0, 0x791fc0\nMOV             X29, SP                                                ; +0x4, 0x791fc4\nSTP             X19, X20, [SP,#0x60+var_50]                            ; +0x8, 0x791fc8\nADRP            X19, #__stack_chk_guard_ptr@PAGE                       ; +0xc, 0x791fcc\nMOV             X20, X0                                                ; +0x10, 0x791fd0\nSTP             X21, X22, [SP,#0x60+var_40]                            ; +0x14, 0x791fd4\nSTR             X23, [SP,#0x60+var_30]                                 ; +0x18, 0x791fd8\nADD             X21, X29, #0x60+var_10                                 ; +0x1c, 0x791fdc\nLDR             X0, [X19,#__stack_chk_guard_ptr@PAGEOFF]; __stack_chk_guard ; +0x20, 0x791fe0\nLDR             X22, [X20,#0x1D8]                                      ; +0x24, 0x791fe4\nLDR             X0, [X0]; this                                         ; +0x28, 0x791fe8\nSTR             X0, [X29,#0x60+var_8]                                  ; +0x2c, 0x791fec\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x30, 0x791ff0\nLDRB            W0, [X0,#0x328]; this                                  ; +0x34, 0x791ff4\nSTRB            W0, [X22,#0x294]                                       ; +0x38, 0x791ff8\nLDR             X22, [X20,#0x1D8]                                      ; +0x3c, 0x791ffc\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x40, 0x792000\nMOV             X23, X0                                                ; +0x44, 0x792004\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x48, 0x792008\nMOV             X2, X0                                                 ; +0x4c, 0x79200c\nMOV             X0, X23; this                                          ; +0x50, 0x792010\nLDR             W3, [X2,#0x2C4]                                        ; +0x54, 0x792014\nLDR             W1, [X2,#0x2C8]                                        ; +0x58, 0x792018\nSUB             W1, W3, W1; int                                        ; +0x5c, 0x79201c\nBL              _ZN11GameManager11colorForIdxEi; GameManager::colorForIdx(int) ; +0x60, 0x792020\nSXTW            X0, W0; this                                           ; +0x64, 0x792024\nUBFX            X2, X0, #8, #8                                         ; +0x68, 0x792028\nUBFX            X1, X0, #0x10, #8                                      ; +0x6c, 0x79202c\nSTRB            W2, [X29,#0x60+var_17]                                 ; +0x70, 0x792030\nSTRB            W1, [X29,#0x60+var_16]                                 ; +0x74, 0x792034\nSTRB            W0, [X29,#0x60+var_18]                                 ; +0x78, 0x792038\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x7c, 0x79203c\nMOV             X23, X0                                                ; +0x80, 0x792040\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x84, 0x792044\nMOV             X2, X0                                                 ; +0x88, 0x792048\nMOV             X0, X23; this                                          ; +0x8c, 0x79204c\nLDR             W3, [X2,#0x2D0]                                        ; +0x90, 0x792050\nLDR             W1, [X2,#0x2D4]                                        ; +0x94, 0x792054\nSUB             W1, W3, W1; int                                        ; +0x98, 0x792058\nBL              _ZN11GameManager11colorForIdxEi; GameManager::colorForIdx(int) ; +0x9c, 0x79205c\nSXTW            X3, W0                                                 ; +0xa0, 0x792060\nADD             X1, X29, #0x60+var_18                                  ; +0xa4, 0x792064\nUBFX            X5, X3, #8, #8                                         ; +0xa8, 0x792068\nUBFX            X4, X3, #0x10, #8                                      ; +0xac, 0x79206c\nMOV             X0, X22                                                ; +0xb0, 0x792070\nMOV             X2, X21                                                ; +0xb4, 0x792074\nSTRB            W3, [X29,#0x60+var_10]                                 ; +0xb8, 0x792078\nSTRB            W5, [X29,#0x60+var_F]                                  ; +0xbc, 0x79207c\nSTRB            W4, [X29,#0x60+var_E]                                  ; +0xc0, 0x792080\nBL              _ZN12SimplePlayer9setColorsERKN7cocos2d10_ccColor3BES3_; SimplePlayer::setColors(cocos2d::_ccColor3B const&,cocos2d::_ccColor3B const&) ; +0xc4, 0x792084\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0xc8, 0x792088\nLDR             W1, [X0,#0x2DC]                                        ; +0xcc, 0x79208c\nLDR             W0, [X0,#0x2E0]                                        ; +0xd0, 0x792090\nSUB             W0, W1, W0; this                                       ; +0xd4, 0x792094\nTBNZ            W0, #0x1F, loc_792118                                  ; +0xd8, 0x792098\nLDR             X22, [X20,#0x1D8]                                      ; +0xdc, 0x79209c\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0xe0, 0x7920a0\nMOV             X23, X0                                                ; +0xe4, 0x7920a4\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0xe8, 0x7920a8\nMOV             X2, X0                                                 ; +0xec, 0x7920ac\nMOV             X0, X23; this                                          ; +0xf0, 0x7920b0\nLDR             W3, [X2,#0x2DC]                                        ; +0xf4, 0x7920b4\nLDR             W1, [X2,#0x2E0]                                        ; +0xf8, 0x7920b8\nSUB             W1, W3, W1; int                                        ; +0xfc, 0x7920bc\nBL              _ZN11GameManager11colorForIdxEi; GameManager::colorForIdx(int) ; +0x100, 0x7920c0\nSXTW            X2, W0                                                 ; +0x104, 0x7920c4\nUBFX            X4, X2, #8, #8                                         ; +0x108, 0x7920c8\nUBFX            X3, X2, #0x10, #8                                      ; +0x10c, 0x7920cc\nMOV             X1, X21                                                ; +0x110, 0x7920d0\nMOV             X0, X22                                                ; +0x114, 0x7920d4\nSTRB            W2, [X29,#0x60+var_10]                                 ; +0x118, 0x7920d8\nSTRB            W4, [X29,#0x60+var_F]                                  ; +0x11c, 0x7920dc\nSTRB            W3, [X29,#0x60+var_E]                                  ; +0x120, 0x7920e0\nBL              _ZN12SimplePlayer21enableCustomGlowColorERKN7cocos2d10_ccColor3BE; SimplePlayer::enableCustomGlowColor(cocos2d::_ccColor3B const&) ; +0x124, 0x7920e4\nLDR             X0, [X20,#0x1D8]; this                                 ; +0x128, 0x7920e8\nBL              _ZN12SimplePlayer12updateColorsEv; SimplePlayer::updateColors(void) ; +0x12c, 0x7920ec\nLDR             X19, [X19,#__stack_chk_guard_ptr@PAGEOFF]; __stack_chk_guard ; +0x130, 0x7920f0\nLDR             X1, [X29,#0x60+var_8]                                  ; +0x134, 0x7920f4\nLDR             X0, [X19]                                              ; +0x138, 0x7920f8\nCMP             X1, X0                                                 ; +0x13c, 0x7920fc\nB.NE            loc_792124                                             ; +0x140, 0x792100\nLDP             X19, X20, [SP,#0x60+var_50]                            ; +0x144, 0x792104\nLDP             X21, X22, [SP,#0x60+var_40]                            ; +0x148, 0x792108\nLDR             X23, [SP,#0x60+var_30]                                 ; +0x14c, 0x79210c\nLDP             X29, X30, [SP+0x60+var_60],#0x60                       ; +0x150, 0x792110\nRET                                                                    ; +0x154, 0x792114\nLDR             X0, [X20,#0x1D8]; this                                 ; +0x158, 0x792118\nBL              _ZN12SimplePlayer22disableCustomGlowColorEv; SimplePlayer::disableCustomGlowColor(void) ; +0x15c, 0x79211c\nB               loc_7920E8                                             ; +0x160, 0x792120\nBL              .__stack_chk_fail                                      ; +0x164, 0x792124", "xrefs": ["GJGarageLayer::playerColorChanged @ 0x79215c", "GJGarageLayer::init @ 0x7995ac", "<???> @ 0x9e0a0"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}