{"type": "func", "start": 5372893328, "end": 5372893484, "name": "SetGroupIDLayer::onNextFreeOrderChannel", "pseudocode": "// \n// SetGroupIDLayer::onNextFreeOrderChannel from 0x1403fd890 to 0x1403fd92c (156 bytes)\n// \n// 2 xrefs:\n// > SetGroupIDLayer::init @ 0x1403f9d9a\n// > <???> @ 0x1406d85dc\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 SetGroupIDLayer::onNextFreeOrderChannel(SetGroupIDLayer *a1, cocos2d::CCObject *a2)\n{\n  __int64 v2; // r8\n  __int64 v4; // rcx\n  std::unordered_set<int> v5; // [rsp+20h] [rbp-48h] BYREF\n  void *v6; // [rsp+70h] [rbp+8h] BYREF\n\n  LODWORD(v6) = 0;\n  sub_14005E660((__int64)&v5, &v6, v2);\n  v4 = qword_1406C2ED8;\n  if ( !qword_1406C2ED8 )\n  {\n    v6 = operator new(0x668u);\n    qword_1406C2ED8 = sub_14017AB00((__int64)v6);\n    (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n    v4 = qword_1406C2ED8;\n  }\n  a1->m_channelValue = LevelEditorLayer::getNextFreeOrderChannel(*(LevelEditorLayer **)(v4 + 528), &v5);\n  sub_14005D100((__int64)&v5._Vec);\n  sub_14005D870((void **)&v5._List._Mypair._Myval2._Myhead);\n  SetGroupIDLayer::updateOrderChannel(a1);\n  SetGroupIDLayer::updateOrderChannelLabel(a1);\n}", "assembly": "; \n; SetGroupIDLayer::onNextFreeOrderChannel from 0x1403fd890 to 0x1403fd92c (156 bytes)\n; \n; 2 xrefs:\n; > SetGroupIDLayer::init @ 0x1403f9d9a\n; > <???> @ 0x1406d85dc\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    rbx                                                            ; +0x0, 0x1403fd890\nsub     rsp, 60h                                                       ; +0x2, 0x1403fd892\nmov     rbx, rcx                                                       ; +0x6, 0x1403fd896\nmov     dword ptr [rsp+68h+arg_0], 0                                   ; +0x9, 0x1403fd899\nlea     rdx, [rsp+68h+arg_0]                                           ; +0x11, 0x1403fd8a1\nlea     rcx, [rsp+68h+var_48]                                          ; +0x16, 0x1403fd8a6\ncall    sub_14005E660                                                  ; +0x1b, 0x1403fd8ab\nnop                                                                    ; +0x20, 0x1403fd8b0\nmov     rcx, cs:qword_1406C2ED8                                        ; +0x21, 0x1403fd8b1\ntest    rcx, rcx                                                       ; +0x28, 0x1403fd8b8\njnz     short loc_1403FD8EC                                            ; +0x2b, 0x1403fd8bb\nmov     ecx, 668h; Size                                                ; +0x2d, 0x1403fd8bd\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x32, 0x1403fd8c2\nmov     [rsp+68h+arg_0], rax                                           ; +0x37, 0x1403fd8c7\nmov     rcx, rax                                                       ; +0x3c, 0x1403fd8cc\ncall    sub_14017AB00                                                  ; +0x3f, 0x1403fd8cf\nnop                                                                    ; +0x44, 0x1403fd8d4\nmov     cs:qword_1406C2ED8, rax                                        ; +0x45, 0x1403fd8d5\nmov     rdx, [rax]                                                     ; +0x4c, 0x1403fd8dc\nmov     rcx, rax                                                       ; +0x4f, 0x1403fd8df\ncall    qword ptr [rdx+48h]                                            ; +0x52, 0x1403fd8e2\nmov     rcx, cs:qword_1406C2ED8                                        ; +0x55, 0x1403fd8e5\nlea     rdx, [rsp+68h+var_48]                                          ; +0x5c, 0x1403fd8ec\nmov     rcx, [rcx+210h]                                                ; +0x61, 0x1403fd8f1\ncall    LevelEditorLayer__getNextFreeOrderChannel                      ; +0x68, 0x1403fd8f8\nmov     [rbx+2DCh], eax                                                ; +0x6d, 0x1403fd8fd\nlea     rcx, [rsp+68h+var_30]                                          ; +0x73, 0x1403fd903\ncall    sub_14005D100                                                  ; +0x78, 0x1403fd908\nlea     rcx, [rsp+68h+var_40]                                          ; +0x7d, 0x1403fd90d\ncall    sub_14005D870                                                  ; +0x82, 0x1403fd912\nmov     rcx, rbx                                                       ; +0x87, 0x1403fd917\ncall    SetGroupIDLayer__updateOrderChannel                            ; +0x8a, 0x1403fd91a\nmov     rcx, rbx                                                       ; +0x8f, 0x1403fd91f\nadd     rsp, 60h                                                       ; +0x92, 0x1403fd922\npop     rbx                                                            ; +0x96, 0x1403fd926\njmp     SetGroupIDLayer__updateOrderChannelLabel                       ; +0x97, 0x1403fd927", "xrefs": ["SetGroupIDLayer::init @ 0x1403f9d9a", "<???> @ 0x1406d85dc"], "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"}