{"type": "func", "start": 4677564, "end": 4677734, "name": "GJBaseGameLayer::activateResetTrigger", "pseudocode": "// \n// GJBaseGameLayer::activateResetTrigger from 0x475fbc to 0x476066 (170 bytes)\n// \n// 1 xrefs:\n// > EffectGameObject::triggerObject @ 0x3ee46a\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::activateResetTrigger(GJBaseGameLayer *a1, EffectGameObject *a2)\n{\n  cocos2d::CCArray *Group; // r0\n  cocos2d::CCArray *v4; // r4\n  cocos2d::ccArray *data; // r3\n  int **arr; // r5\n  int **v7; // r6\n  int *v8; // r4\n  int *v9; // t1\n  GJEffectManager *m_effectManager; // r0\n  int v11; // r1\n  int m_uniqueID; // r2\n\n  Group = GJBaseGameLayer::getGroup(a1, a2->m_targetGroupID);\n  v4 = Group;\n  if ( Group )\n  {\n    if ( cocos2d::CCArray::count(Group) )\n    {\n      data = v4->data;\n      if ( data->num )\n      {\n        arr = (int **)data->arr;\n        v7 = &(&arr[data->num])[-1];\n        while ( 1 )\n        {\n          if ( arr > v7 )\n            return;\n          v9 = *arr++;\n          v8 = v9;\n          if ( !v9 )\n            return;\n          if ( v8[221] == 2063 )\n            break;\n          if ( (*(int (__fastcall **)(int *))(*v8 + 892))(v8) == 30\n            || (*(int (__fastcall **)(int *))(*v8 + 892))(v8) == 21 )\n          {\n            m_effectManager = a1->m_effectManager;\n            m_uniqueID = 0;\n            v11 = v8[193];\nLABEL_12:\n            GJEffectManager::removeTriggeredID(m_effectManager, v11, m_uniqueID);\n            (*(void (__fastcall **)(int *))(*v8 + 748))(v8);\n          }\n        }\n        GJEffectManager::removeTriggeredID(a1->m_effectManager, v8[193], a1->m_player1->m_uniqueID);\n        m_effectManager = a1->m_effectManager;\n        v11 = v8[193];\n        m_uniqueID = a1->m_player2->m_uniqueID;\n        goto LABEL_12;\n      }\n    }\n  }\n}", "assembly": "; \n; GJBaseGameLayer::activateResetTrigger from 0x475fbc to 0x476066 (170 bytes)\n; \n; 1 xrefs:\n; > EffectGameObject::triggerObject @ 0x3ee46a\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\nPUSH.W          {R4-R8,LR}                                             ; +0x0, 0x475fbc\nMOV             R7, R0                                                 ; +0x4, 0x475fc0\nLDR.W           R1, [R1,#0x4FC]; int                                   ; +0x6, 0x475fc2\nBL              _ZN15GJBaseGameLayer8getGroupEi; GJBaseGameLayer::getGroup(int) ; +0xa, 0x475fc6\nMOV             R4, R0                                                 ; +0xe, 0x475fca\nCMP             R0, #0                                                 ; +0x10, 0x475fcc\nBEQ             locret_476062                                          ; +0x12, 0x475fce\nBL              _ZNK7cocos2d7CCArray5countEv; cocos2d::CCArray::count(void) ; +0x14, 0x475fd0\nCMP             R0, #0                                                 ; +0x18, 0x475fd4\nBEQ             locret_476062                                          ; +0x1a, 0x475fd6\nLDR             R3, [R4,#0x34]                                         ; +0x1c, 0x475fd8\nLDR             R4, [R3]                                               ; +0x1e, 0x475fda\nCMP             R4, #0                                                 ; +0x20, 0x475fdc\nBEQ             locret_476062                                          ; +0x22, 0x475fde\nADD.W           R4, R4, #0x40000000                                    ; +0x24, 0x475fe0\nLDR             R5, [R3,#0xC]                                          ; +0x28, 0x475fe4\nSUBS            R4, #1                                                 ; +0x2a, 0x475fe6\nMOVW            R8, #0x80F                                             ; +0x2c, 0x475fe8\nADD.W           R6, R5, R4,LSL#2                                       ; +0x30, 0x475fec\nCMP             R5, R6                                                 ; +0x34, 0x475ff0\nBHI             locret_476062                                          ; +0x36, 0x475ff2\nLDR.W           R4, [R5],#4                                            ; +0x38, 0x475ff4\nCBNZ            R4, loc_475FFE                                         ; +0x3c, 0x475ff8\nPOP.W           {R4-R8,PC}                                             ; +0x3e, 0x475ffa\nLDR.W           R3, [R4,#0x374]                                        ; +0x42, 0x475ffe\nCMP             R3, R8                                                 ; +0x46, 0x476002\nBNE             loc_47602C                                             ; +0x48, 0x476004\nLDR.W           R3, [R7,#0x8B8]                                        ; +0x4a, 0x476006\nLDR.W           R0, [R7,#0x690]; this                                  ; +0x4e, 0x47600a\nLDR.W           R1, [R4,#0x304]; int                                   ; +0x52, 0x47600e\nLDR.W           R2, [R3,#0x304]; int                                   ; +0x56, 0x476012\nBL              _ZN15GJEffectManager17removeTriggeredIDEii; GJEffectManager::removeTriggeredID(int,int) ; +0x5a, 0x476016\nLDR.W           R3, [R7,#0x8BC]                                        ; +0x5e, 0x47601a\nLDR.W           R0, [R7,#0x690]                                        ; +0x62, 0x47601e\nLDR.W           R1, [R4,#0x304]                                        ; +0x66, 0x476022\nLDR.W           R2, [R3,#0x304]                                        ; +0x6a, 0x476026\nB               loc_476052                                             ; +0x6e, 0x47602a\nLDR             R3, [R4]                                               ; +0x70, 0x47602c\nMOV             R0, R4                                                 ; +0x72, 0x47602e\nLDR.W           R3, [R3,#0x37C]                                        ; +0x74, 0x476030\nBLX             R3                                                     ; +0x78, 0x476034\nCMP             R0, #0x1E                                              ; +0x7a, 0x476036\nBEQ             loc_476048                                             ; +0x7c, 0x476038\nLDR             R3, [R4]                                               ; +0x7e, 0x47603a\nMOV             R0, R4                                                 ; +0x80, 0x47603c\nLDR.W           R3, [R3,#0x37C]                                        ; +0x82, 0x47603e\nBLX             R3                                                     ; +0x86, 0x476042\nCMP             R0, #0x15                                              ; +0x88, 0x476044\nBNE             loc_475FF0                                             ; +0x8a, 0x476046\nLDR.W           R0, [R7,#0x690]; this                                  ; +0x8c, 0x476048\nMOVS            R2, #0; int                                            ; +0x90, 0x47604c\nLDR.W           R1, [R4,#0x304]; int                                   ; +0x92, 0x47604e\nBL              _ZN15GJEffectManager17removeTriggeredIDEii; GJEffectManager::removeTriggeredID(int,int) ; +0x96, 0x476052\nLDR             R3, [R4]                                               ; +0x9a, 0x476056\nMOV             R0, R4                                                 ; +0x9c, 0x476058\nLDR.W           R3, [R3,#0x2EC]                                        ; +0x9e, 0x47605a\nBLX             R3                                                     ; +0xa2, 0x47605e\nB               loc_475FF0                                             ; +0xa4, 0x476060\nPOP.W           {R4-R8,PC}                                             ; +0xa6, 0x476062", "xrefs": ["EffectGameObject::triggerObject @ 0x3ee46a"], "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"}