{"type": "func", "start": 4654068, "end": 4654148, "name": "GJBaseGameLayer::resetGradientLayers", "pseudocode": "// \n// GJBaseGameLayer::resetGradientLayers from 0x4703f4 to 0x470444 (80 bytes)\n// \n// 3 xrefs:\n// > LevelEditorLayer::updateGameObjects @ 0x375d84\n// > GJBaseGameLayer::triggerGradientCommand @ 0x47c968\n// > GJBaseGameLayer::resetLevelVariables @ 0x491d44\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 GJBaseGameLayer::resetGradientLayers(GJBaseGameLayer *a1)\n{\n  cocos2d::CCDictionary *m_gradientLayers; // r3\n  cocos2d::CCDictElement *m_pElements; // r3\n  cocos2d::CCDictElement *next; // r4\n  cocos2d::CCObject *m_pObject; // r5\n  cocos2d::CCObject_vtbl *v5; // r3\n  cocos2d::CCDictElement *v6; // r2\n\n  m_gradientLayers = a1->m_gradientLayers;\n  if ( m_gradientLayers )\n  {\n    m_pElements = m_gradientLayers->m_pElements;\n    if ( m_pElements )\n      next = (cocos2d::CCDictElement *)m_pElements->hh.next;\n    else\n      next = nullptr;\n    while ( m_pElements )\n    {\n      m_pObject = m_pElements->m_pObject;\n      m_pObject->__vftable[6].acceptVisitor(m_pObject, nullptr);\n      v5 = m_pObject->__vftable;\n      m_pObject[9].m_nLuaID = 0;\n      LOBYTE(m_pObject[9].m_nTag) = 0;\n      ((void (__fastcall *)(cocos2d::CCObject *, _DWORD))v5[4].~CCObject)(m_pObject, 0);\n      if ( next )\n        v6 = (cocos2d::CCDictElement *)next->hh.next;\n      else\n        v6 = nullptr;\n      m_pElements = next;\n      next = v6;\n    }\n  }\n}", "assembly": "; \n; GJBaseGameLayer::resetGradientLayers from 0x4703f4 to 0x470444 (80 bytes)\n; \n; 3 xrefs:\n; > LevelEditorLayer::updateGameObjects @ 0x375d84\n; > GJBaseGameLayer::triggerGradientCommand @ 0x47c968\n; > GJBaseGameLayer::resetLevelVariables @ 0x491d44\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\nMOVW            R3, #0x2A74                                            ; +0x0, 0x4703f4\nLDR             R3, [R0,R3]                                            ; +0x4, 0x4703f8\nPUSH            {R4-R6,LR}                                             ; +0x6, 0x4703fa\nCBZ             R3, locret_470442                                      ; +0x8, 0x4703fc\nLDR             R3, [R3,#0x34]                                         ; +0xa, 0x4703fe\nCBZ             R3, loc_470408                                         ; +0xc, 0x470400\nLDR.W           R4, [R3,#0x110]                                        ; +0xe, 0x470402\nB               loc_47040A                                             ; +0x12, 0x470406\nMOV             R4, R3                                                 ; +0x14, 0x470408\nMOVS            R6, #0                                                 ; +0x16, 0x47040a\nCBZ             R3, locret_470442                                      ; +0x18, 0x47040c\nLDR.W           R5, [R3,#0x104]                                        ; +0x1a, 0x47040e\nMOVS            R1, #0                                                 ; +0x1e, 0x470412\nLDR             R3, [R5]                                               ; +0x20, 0x470414\nMOV             R0, R5                                                 ; +0x22, 0x470416\nLDR.W           R3, [R3,#0x100]                                        ; +0x24, 0x470418\nBLX             R3                                                     ; +0x28, 0x47041c\nLDR             R3, [R5]                                               ; +0x2a, 0x47041e\nSTR.W           R6, [R5,#0x1DC]                                        ; +0x2c, 0x470420\nMOV             R0, R5                                                 ; +0x30, 0x470424\nSTRB.W          R6, [R5,#0x1E0]                                        ; +0x32, 0x470426\nMOVS            R1, #0                                                 ; +0x36, 0x47042a\nLDR.W           R3, [R3,#0xA4]                                         ; +0x38, 0x47042c\nBLX             R3                                                     ; +0x3c, 0x470430\nCBZ             R4, loc_47043A                                         ; +0x3e, 0x470432\nLDR.W           R2, [R4,#0x110]                                        ; +0x40, 0x470434\nB               loc_47043C                                             ; +0x44, 0x470438\nMOV             R2, R4                                                 ; +0x46, 0x47043a\nMOV             R3, R4                                                 ; +0x48, 0x47043c\nMOV             R4, R2                                                 ; +0x4a, 0x47043e\nB               loc_47040C                                             ; +0x4c, 0x470440\nPOP             {R4-R6,PC}                                             ; +0x4e, 0x470442", "xrefs": ["LevelEditorLayer::updateGameObjects @ 0x375d84", "GJBaseGameLayer::triggerGradientCommand @ 0x47c968", "GJBaseGameLayer::resetLevelVariables @ 0x491d44"], "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"}