{"type": "func", "start": 4739752, "end": 4739848, "name": "EditorUI::onGoToFreeLayer", "pseudocode": "// \n// EditorUI::onGoToFreeLayer from 0x4852a8 to 0x485308 (96 bytes)\n// \n// 1 xrefs:\n// > EditorUI::handleEditorAction @ 0x6f21aa\n// \n// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:49:24 +0000\n// \n\nint __fastcall EditorUI::onGoToFreeLayer(EditorUI *this, cocos2d::CCObject *a2)\n{\n  LevelEditorLayer *v3; // r0\n  __int16 NextFreeEditorLayer; // r7\n  int v5; // r1\n  _DWORD v7[5]; // [sp+0h] [bp-1Ch] BYREF\n\n  v3 = *((LevelEditorLayer **)this + 236);\n  memset(v7, 0, 16);\n  v7[4] = 1065353216;\n  NextFreeEditorLayer = LevelEditorLayer::getNextFreeEditorLayer(v3, (int)v7);\n  std::__hash_table<int,std::hash<int>,std::equal_to<int>,std::allocator<int>>::~__hash_table((int)v7);\n  *(_WORD *)(*((_DWORD *)this + 236) + 11826) = NextFreeEditorLayer;\n  return EditorUI::updateGroupIDLabel(this, v5);\n}", "assembly": "; \n; EditorUI::onGoToFreeLayer from 0x4852a8 to 0x485308 (96 bytes)\n; \n; 1 xrefs:\n; > EditorUI::handleEditorAction @ 0x6f21aa\n; \n; This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:49:24 +0000\n; \nLDR             R3, =(__stack_chk_guard_ptr - 0x4852B0)                ; +0x0, 0x4852a8\nPUSH            {R4-R7,LR}                                             ; +0x2, 0x4852aa\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0x4, 0x4852ac\nLDR             R3, [R3]; __stack_chk_guard                            ; +0x6, 0x4852ae\nSUB             SP, SP, #0x1C                                          ; +0x8, 0x4852b0\nMOV             R6, R0                                                 ; +0xa, 0x4852b2\nLDR             R2, [R3]                                               ; +0xc, 0x4852b4\nMOV             R4, R3                                                 ; +0xe, 0x4852b6\nLDR.W           R0, [R0,#0x3B0]                                        ; +0x10, 0x4852b8\nMOV             R1, SP                                                 ; +0x14, 0x4852bc\nMOV             R5, SP                                                 ; +0x16, 0x4852be\nSTR             R2, [SP,#0x1C+var_8]                                   ; +0x18, 0x4852c0\nMOVS            R2, #0                                                 ; +0x1a, 0x4852c2\nSTR             R2, [SP,#0x1C+var_1C]                                  ; +0x1c, 0x4852c4\nSTR             R2, [SP,#0x1C+var_18]                                  ; +0x1e, 0x4852c6\nSTR             R2, [SP,#0x1C+var_14]                                  ; +0x20, 0x4852c8\nSTR             R2, [SP,#0x1C+var_10]                                  ; +0x22, 0x4852ca\nMOV.W           R2, #0x3F800000                                        ; +0x24, 0x4852cc\nSTR             R2, [SP,#0x1C+var_C]                                   ; +0x28, 0x4852d0\nBL              _ZN16LevelEditorLayer22getNextFreeEditorLayerERKNSt6__ndk113unordered_setIiNS0_4hashIiEENS0_8equal_toIiEENS0_9allocatorIiEEEE; LevelEditorLayer::getNextFreeEditorLayer(std::unordered_set<int> const&) ; +0x2a, 0x4852d2\nMOV             R7, R0                                                 ; +0x2e, 0x4852d6\nMOV             R0, SP                                                 ; +0x30, 0x4852d8\nBL              _ZNSt6__ndk112__hash_tableIiNS_4hashIiEENS_8equal_toIiEENS_9allocatorIiEEED2Ev; std::__hash_table<int,std::hash<int>,std::equal_to<int>,std::allocator<int>>::~__hash_table() ; +0x32, 0x4852da\nLDR.W           R2, [R6,#0x3B0]                                        ; +0x36, 0x4852de\nMOVW            R3, #0x2E32                                            ; +0x3a, 0x4852e2\nMOV             R0, R6; this                                           ; +0x3e, 0x4852e6\nSTRH            R7, [R2,R3]                                            ; +0x40, 0x4852e8\nBL              _ZN8EditorUI18updateGroupIDLabelEv; EditorUI::updateGroupIDLabel(void) ; +0x42, 0x4852ea\nLDR             R2, [SP,#0x1C+var_8]                                   ; +0x46, 0x4852ee\nLDR             R3, [R4]                                               ; +0x48, 0x4852f0\nCMP             R2, R3                                                 ; +0x4a, 0x4852f2\nBEQ             loc_485304                                             ; +0x4c, 0x4852f4\nBLX             __stack_chk_fail                                       ; +0x4e, 0x4852f6\nMOV             R0, R5                                                 ; +0x52, 0x4852fa\nBL              _ZNSt6__ndk112__hash_tableIiNS_4hashIiEENS_8equal_toIiEENS_9allocatorIiEEED2Ev; std::__hash_table<int,std::hash<int>,std::equal_to<int>,std::allocator<int>>::~__hash_table() ; +0x54, 0x4852fc\nBL              __cxa_end_cleanup                                      ; +0x58, 0x485300\nADD             SP, SP, #0x1C                                          ; +0x5c, 0x485304\nPOP             {R4-R7,PC}                                             ; +0x5e, 0x485306", "xrefs": ["EditorUI::handleEditorAction @ 0x6f21aa"], "is_objc": false, "is_32_bit": true, "is_64_bit": false, "idp_name": "arm", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}