{"type": "func", "start": 9172200, "end": 9172368, "name": "GJEffectManager::getColorSprite", "pseudocode": "// \n// GJEffectManager::getColorSprite from 0x8bf4e8 to 0x8bf590 (168 bytes)\n// \n// 15 xrefs:\n// > GameObject::setupColorSprite @ 0x64aa90\n// > GameObject::setupColorSprite @ 0x64aaa4\n// > LevelEditorLayer::transferDefaultColors @ 0x65fe88\n// > LevelEditorLayer::transferDefaultColors @ 0x65feb4\n// > LevelEditorLayer::transferDefaultColors @ 0x65fee0\n// > LevelEditorLayer::transferDefaultColors @ 0x65ff0c\n// > GJBaseGameLayer::updateColor @ 0x855588\n// > GJEffectManager::activeColorForIndex @ 0x8bf5ac\n// > GJEffectManager::activeOpacityForIndex @ 0x8bfa20\n// > GJEffectManager::calculateLightBGColor @ 0x8bfb10\n// > GJEffectManager::calculateLightBGColor @ 0x8bfb30\n// > GJEffectManager::setColorAction @ 0x8bfbc8\n// > GJEffectManager::calculateInheritedColor @ 0x8c0b5c\n// > GJEffectManager::processCopyColorPulseActions @ 0x8c149c\n// > <???> @ 0xac1a0\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\nColorActionSprite *GJEffectManager::getColorSprite(GJEffectManager *a1, int a2)\n{\n  int v2; // w19\n  __int64 v3; // x22\n  ColorActionSprite *v4; // x20\n  ColorActionSprite *v7; // x20\n  GJEffectManager_vtbl *v8; // x2\n\n  if ( a2 > 1100 )\n  {\n    v3 = 1101;\n    v2 = 1101;\n    v4 = a1->m_colorActionSpriteVector.m_start[1101];\n    if ( v4 )\n      return v4;\n  }\n  else\n  {\n    if ( a2 < 0 )\n      v2 = 0;\n    else\n      v2 = a2;\n    v3 = v2;\n    v4 = a1->m_colorActionSpriteVector.m_start[v3];\n    if ( v4 )\n      return v4;\n  }\n  v7 = ColorActionSprite::create();\n  v8 = a1->__vftable;\n  v7->m_colorID = v2;\n  v8->addChild(a1, v7);\n  a1->m_colorActionSpriteVector.m_start[v3] = v7;\n  cocos2d::CCDictionary::setObject(a1->m_unkDict150, v7, v2);\n  return v7;\n}", "assembly": "; \n; GJEffectManager::getColorSprite from 0x8bf4e8 to 0x8bf590 (168 bytes)\n; \n; 15 xrefs:\n; > GameObject::setupColorSprite @ 0x64aa90\n; > GameObject::setupColorSprite @ 0x64aaa4\n; > LevelEditorLayer::transferDefaultColors @ 0x65fe88\n; > LevelEditorLayer::transferDefaultColors @ 0x65feb4\n; > LevelEditorLayer::transferDefaultColors @ 0x65fee0\n; > LevelEditorLayer::transferDefaultColors @ 0x65ff0c\n; > GJBaseGameLayer::updateColor @ 0x855588\n; > GJEffectManager::activeColorForIndex @ 0x8bf5ac\n; > GJEffectManager::activeOpacityForIndex @ 0x8bfa20\n; > GJEffectManager::calculateLightBGColor @ 0x8bfb10\n; > GJEffectManager::calculateLightBGColor @ 0x8bfb30\n; > GJEffectManager::setColorAction @ 0x8bfbc8\n; > GJEffectManager::calculateInheritedColor @ 0x8c0b5c\n; > GJEffectManager::processCopyColorPulseActions @ 0x8c149c\n; > <???> @ 0xac1a0\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,#-0x30+var_s0]!                          ; +0x0, 0x8bf4e8\nCMP             W1, #0x44C                                             ; +0x4, 0x8bf4ec\nMOV             X29, SP                                                ; +0x8, 0x8bf4f0\nSTP             X19, X20, [SP,#var_s10]                                ; +0xc, 0x8bf4f4\nSTP             X21, X22, [SP,#var_s20]                                ; +0x10, 0x8bf4f8\nB.GT            loc_8BF52C                                             ; +0x14, 0x8bf4fc\nCMP             W1, WZR                                                ; +0x18, 0x8bf500\nCSEL            W19, W1, WZR, GE                                       ; +0x1c, 0x8bf504\nLDR             X1, [X0,#0x2D8]                                        ; +0x20, 0x8bf508\nSBFIZ           X22, X19, #3, #0x20 ; ' '                              ; +0x24, 0x8bf50c\nLDR             X20, [X1,X22]                                          ; +0x28, 0x8bf510\nCBZ             X20, loc_8BF540                                        ; +0x2c, 0x8bf514\nMOV             X0, X20; this                                          ; +0x30, 0x8bf518\nLDP             X19, X20, [SP,#var_s10]                                ; +0x34, 0x8bf51c\nLDP             X21, X22, [SP,#var_s20]                                ; +0x38, 0x8bf520\nLDP             X29, X30, [SP+var_s0],#0x30                            ; +0x3c, 0x8bf524\nRET                                                                    ; +0x40, 0x8bf528\nMOV             X22, #0x2268                                           ; +0x44, 0x8bf52c\nLDR             X1, [X0,#0x2D8]                                        ; +0x48, 0x8bf530\nMOV             W19, #0x44D                                            ; +0x4c, 0x8bf534\nLDR             X20, [X1,X22]                                          ; +0x50, 0x8bf538\nCBNZ            X20, loc_8BF518                                        ; +0x54, 0x8bf53c\nMOV             X21, X0                                                ; +0x58, 0x8bf540\nBL              _ZN17ColorActionSprite6createEv; ColorActionSprite::create(void) ; +0x5c, 0x8bf544\nMOV             X20, X0                                                ; +0x60, 0x8bf548\nMOV             X0, X21                                                ; +0x64, 0x8bf54c\nMOV             X1, X20                                                ; +0x68, 0x8bf550\nLDR             X2, [X21]                                              ; +0x6c, 0x8bf554\nSTR             W19, [X20,#0x148]                                      ; +0x70, 0x8bf558\nLDR             X2, [X2,#0x1B8]                                        ; +0x74, 0x8bf55c\nBLR             X2                                                     ; +0x78, 0x8bf560\nLDR             X0, [X21,#0x2D8]                                       ; +0x7c, 0x8bf564\nMOV             X1, X20; cocos2d::CCObject *                           ; +0x80, 0x8bf568\nSXTW            X2, W19; __int64                                       ; +0x84, 0x8bf56c\nSTR             X20, [X0,X22]                                          ; +0x88, 0x8bf570\nLDR             X0, [X21,#0x150]; this                                 ; +0x8c, 0x8bf574\nBL              _ZN7cocos2d12CCDictionary9setObjectEPNS_8CCObjectEl; cocos2d::CCDictionary::setObject(cocos2d::CCObject *,long) ; +0x90, 0x8bf578\nMOV             X0, X20                                                ; +0x94, 0x8bf57c\nLDP             X19, X20, [SP,#var_s10]                                ; +0x98, 0x8bf580\nLDP             X21, X22, [SP,#var_s20]                                ; +0x9c, 0x8bf584\nLDP             X29, X30, [SP+var_s0],#0x30                            ; +0xa0, 0x8bf588\nRET                                                                    ; +0xa4, 0x8bf58c", "xrefs": ["GameObject::setupColorSprite @ 0x64aa90", "GameObject::setupColorSprite @ 0x64aaa4", "LevelEditorLayer::transferDefaultColors @ 0x65fe88", "LevelEditorLayer::transferDefaultColors @ 0x65feb4", "LevelEditorLayer::transferDefaultColors @ 0x65fee0", "LevelEditorLayer::transferDefaultColors @ 0x65ff0c", "GJBaseGameLayer::updateColor @ 0x855588", "GJEffectManager::activeColorForIndex @ 0x8bf5ac", "GJEffectManager::activeOpacityForIndex @ 0x8bfa20", "GJEffectManager::calculateLightBGColor @ 0x8bfb10", "GJEffectManager::calculateLightBGColor @ 0x8bfb30", "GJEffectManager::setColorAction @ 0x8bfbc8", "GJEffectManager::calculateInheritedColor @ 0x8c0b5c", "GJEffectManager::processCopyColorPulseActions @ 0x8c149c", "<???> @ 0xac1a0"], "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"}