{"type": "func", "start": 5370955664, "end": 5370955869, "name": "GJBaseGameLayer::removeGroupParent", "pseudocode": "// \n// GJBaseGameLayer::removeGroupParent from 0x140224790 to 0x14022485d (205 bytes)\n// \n// 8 xrefs:\n// > GJBaseGameLayer::removeFromGroup @ 0x14022425e\n// > GJBaseGameLayer::setGroupParent @ 0x1402246df\n// > LevelEditorLayer::removeFromGroup @ 0x1402dec6e\n// > SetGroupIDLayer::callRemoveFromGroup @ 0x1403fc86a\n// > <???> @ 0x140680088\n// > <???> @ 0x1406800bc\n// > <???> @ 0x1406cd71c\n// > <???> @ 0x1406cd728\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::removeGroupParent(GJBaseGameLayer *a1, int a2)\n{\n  __int64 v2; // rsi\n  struct cocos2d::CCObject *v4; // rax\n  struct cocos2d::CCObject *v5; // rbp\n  cocos2d::CCArray *v6; // rax\n  cocos2d::CCArray *v7; // rdi\n  unsigned int v8; // ebx\n\n  v2 = a2;\n  v4 = cocos2d::CCDictionary::objectForKey(a1->m_parentGroupsDict, a2);\n  v5 = v4;\n  if ( v4 )\n  {\n    v6 = (cocos2d::CCArray *)cocos2d::CCDictionary::objectForKey(a1->m_parentGroupIDs, (unsigned int)v4[16].m_eObjType);\n    v7 = v6;\n    if ( !v6 )\n      goto LABEL_9;\n    v8 = 0;\n    if ( cocos2d::CCArray::count(v6) )\n    {\n      while ( LODWORD(cocos2d::CCArray::objectAtIndex(v7, v8)[1].__vftable) != (_DWORD)v2 )\n      {\n        if ( ++v8 >= cocos2d::CCArray::count(v7) )\n          goto LABEL_8;\n      }\n      cocos2d::CCArray::removeObjectAtIndex(v7, v8, 1);\n    }\nLABEL_8:\n    if ( !cocos2d::CCArray::count(v7) )\nLABEL_9:\n      BYTE2(v5[21].__vftable) = 0;\n    cocos2d::CCDictionary::removeObjectForKey(a1->m_parentGroupsDict, v2);\n  }\n}", "assembly": "; \n; GJBaseGameLayer::removeGroupParent from 0x140224790 to 0x14022485d (205 bytes)\n; \n; 8 xrefs:\n; > GJBaseGameLayer::removeFromGroup @ 0x14022425e\n; > GJBaseGameLayer::setGroupParent @ 0x1402246df\n; > LevelEditorLayer::removeFromGroup @ 0x1402dec6e\n; > SetGroupIDLayer::callRemoveFromGroup @ 0x1403fc86a\n; > <???> @ 0x140680088\n; > <???> @ 0x1406800bc\n; > <???> @ 0x1406cd71c\n; > <???> @ 0x1406cd728\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\nmov     [rsp+arg_10], rbp                                              ; +0x0, 0x140224790\npush    rsi                                                            ; +0x5, 0x140224795\npush    r14                                                            ; +0x6, 0x140224796\npush    r15                                                            ; +0x8, 0x140224798\nsub     rsp, 20h                                                       ; +0xa, 0x14022479a\nmovsxd  rsi, edx                                                       ; +0xe, 0x14022479e\nmov     r14, rcx                                                       ; +0x11, 0x1402247a1\nmov     rcx, [rcx+0F60h]                                               ; +0x14, 0x1402247a4\nmov     rdx, rsi                                                       ; +0x1b, 0x1402247ab\ncall    cs:?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::objectForKey(__int64) ; +0x1e, 0x1402247ae\nmov     rbp, rax                                                       ; +0x24, 0x1402247b4\ntest    rax, rax                                                       ; +0x27, 0x1402247b7\njz      loc_14022484E                                                  ; +0x2a, 0x1402247ba\nmov     edx, [rax+39Ch]                                                ; +0x30, 0x1402247c0\nmov     rcx, [r14+0F68h]                                               ; +0x36, 0x1402247c6\nmov     [rsp+38h+arg_8], rdi                                           ; +0x3d, 0x1402247cd\ncall    cs:?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::objectForKey(__int64) ; +0x42, 0x1402247d2\nmov     rdi, rax                                                       ; +0x48, 0x1402247d8\ntest    rax, rax                                                       ; +0x4b, 0x1402247db\njz      short loc_140224832                                            ; +0x4e, 0x1402247de\nmov     [rsp+38h+arg_0], rbx                                           ; +0x50, 0x1402247e0\nmov     rcx, rax                                                       ; +0x55, 0x1402247e5\nxor     ebx, ebx                                                       ; +0x58, 0x1402247e8\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x5a, 0x1402247ea\ntest    eax, eax                                                       ; +0x60, 0x1402247f0\njz      short loc_140224820                                            ; +0x62, 0x1402247f2\nmov     edx, ebx                                                       ; +0x64, 0x1402247f4\nmov     rcx, rdi                                                       ; +0x66, 0x1402247f6\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x69, 0x1402247f9\nmov     rcx, rdi                                                       ; +0x6f, 0x1402247ff\ncmp     [rax+38h], esi                                                 ; +0x72, 0x140224802\njz      short loc_140224815                                            ; +0x75, 0x140224805\ninc     ebx                                                            ; +0x77, 0x140224807\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x79, 0x140224809\ncmp     ebx, eax                                                       ; +0x7f, 0x14022480f\njb      short loc_1402247F4                                            ; +0x81, 0x140224811\njmp     short loc_140224820                                            ; +0x83, 0x140224813\nmov     r8b, 1                                                         ; +0x85, 0x140224815\nmov     edx, ebx                                                       ; +0x88, 0x140224818\ncall    cs:?removeObjectAtIndex@CCArray@cocos2d@@QEAAXI_N@Z; cocos2d::CCArray::removeObjectAtIndex(uint,bool) ; +0x8a, 0x14022481a\nmov     rcx, rdi                                                       ; +0x90, 0x140224820\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x93, 0x140224823\nmov     rbx, [rsp+38h+arg_0]                                           ; +0x99, 0x140224829\ntest    eax, eax                                                       ; +0x9e, 0x14022482e\njnz     short loc_140224839                                            ; +0xa0, 0x140224830\nmov     byte ptr [rbp+49Ah], 0                                         ; +0xa2, 0x140224832\nmov     rcx, [r14+0F60h]                                               ; +0xa9, 0x140224839\nmov     rdx, rsi                                                       ; +0xb0, 0x140224840\ncall    cs:?removeObjectForKey@CCDictionary@cocos2d@@QEAAX_J@Z; cocos2d::CCDictionary::removeObjectForKey(__int64) ; +0xb3, 0x140224843\nmov     rdi, [rsp+38h+arg_8]                                           ; +0xb9, 0x140224849\nmov     rbp, [rsp+38h+arg_10]                                          ; +0xbe, 0x14022484e\nadd     rsp, 20h                                                       ; +0xc3, 0x140224853\npop     r15                                                            ; +0xc7, 0x140224857\npop     r14                                                            ; +0xc9, 0x140224859\npop     rsi                                                            ; +0xcb, 0x14022485b\nretn                                                                   ; +0xcc, 0x14022485c", "xrefs": ["GJBaseGameLayer::removeFromGroup @ 0x14022425e", "GJBaseGameLayer::setGroupParent @ 0x1402246df", "LevelEditorLayer::removeFromGroup @ 0x1402dec6e", "SetGroupIDLayer::callRemoveFromGroup @ 0x1403fc86a", "<???> @ 0x140680088", "<???> @ 0x1406800bc", "<???> @ 0x1406cd71c", "<???> @ 0x1406cd728"], "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"}