{"type": "func", "start": 4742224, "end": 4742378, "name": "EditorUI::showMaxError", "pseudocode": "// \n// EditorUI::showMaxError from 0x485c50 to 0x485cea (154 bytes)\n// \n// 4 xrefs:\n// > LevelEditorLayer::createObjectsFromString @ 0x46e810\n// > EditorUI::onCreate @ 0x48783e\n// > EditorUI::doPasteObjects @ 0x6f3260\n// > EditorUI::onDuplicate @ 0x6f39ce\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:25 +0000\n// \n\nint __fastcall EditorUI::showMaxError(int this)\n{\n  int v1; // r4\n  int v2; // r5\n  cocos2d::CCString *v3; // r0\n  const char *CString; // r7\n  size_t v5; // r0\n  int *v6; // r5\n  int v7[3]; // [sp+8h] [bp-14h] BYREF\n\n  v1 = *(unsigned __int8 *)(this + 464);\n  v2 = this;\n  if ( !*(_BYTE *)(this + 464) )\n  {\n    *(_BYTE *)(this + 464) = 1;\n    v3 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(\n                                (cocos2d::CCString *)\"You have reached the upper max limit of <cg>%i</c> objects. This li\"\n                                                     \"mit can be removed completely, but it is <cr>not</c> recommended. L\"\n                                                     \"evels with object count above this limit will display a <co>warning\"\n                                                     \"</c> when played online.\\n\"\n                                                     \"<cy>Unoptimized levels that use too many objects have a lower chanc\"\n                                                     \"e of being rated and featured.</c>\",\n                                (const char *)&stru_1387C.st_value);\n    v7[0] = v1;\n    v7[1] = v1;\n    v7[2] = v1;\n    CString = (const char *)cocos2d::CCString::getCString(v3);\n    v5 = strlen(CString);\n    std::string::__init(v7, CString, v5);\n    v6 = FLAlertLayer::create(\n           v2 + 316,\n           (cocos2d::CCLabelBMFont *)\"Max Objects\",\n           (int)v7,\n           (ButtonSprite *)\"Cancel\",\n           (ButtonSprite *)\"Unlimited\",\n           380.0);\n    std::string::~string((int)v7);\n    (*(void (__fastcall **)(int *, int))(*v6 + 36))(v6, 126);\n    return (*(int (__fastcall **)(int *))(*v6 + 656))(v6);\n  }\n  return this;\n}", "assembly": "; \n; EditorUI::showMaxError from 0x485c50 to 0x485cea (154 bytes)\n; \n; 4 xrefs:\n; > LevelEditorLayer::createObjectsFromString @ 0x46e810\n; > EditorUI::onCreate @ 0x48783e\n; > EditorUI::doPasteObjects @ 0x6f3260\n; > EditorUI::onDuplicate @ 0x6f39ce\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:25 +0000\n; \nLDR             R3, =(__stack_chk_guard_ptr - 0x485C58)                ; +0x0, 0x485c50\nPUSH            {R4-R7,LR}                                             ; +0x2, 0x485c52\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0x4, 0x485c54\nLDR             R3, [R3]; __stack_chk_guard                            ; +0x6, 0x485c56\nLDRB.W          R4, [R0,#0x1D0]                                        ; +0x8, 0x485c58\nSUB             SP, SP, #0x1C                                          ; +0xc, 0x485c5c\nLDR             R2, [R3]                                               ; +0xe, 0x485c5e\nMOV             R5, R0                                                 ; +0x10, 0x485c60\nMOV             R6, R3                                                 ; +0x12, 0x485c62\nSTR             R2, [SP,#0x1C+var_8]                                   ; +0x14, 0x485c64\nCMP             R4, #0                                                 ; +0x16, 0x485c66\nBNE             loc_485CDA                                             ; +0x18, 0x485c68\nMOVS            R3, #1                                                 ; +0x1a, 0x485c6a\nSTRB.W          R3, [R0,#0x1D0]                                        ; +0x1c, 0x485c6c\nLDR             R0, =(aYouHaveReached - 0x485C78); \"You have reached the upper max limit of\"... ; +0x20, 0x485c70\nLDR             R1, =0x13880; char *                                   ; +0x22, 0x485c72\nADD             R0, PC; \"You have reached the upper max limit of\"...   ; +0x24, 0x485c74\nBL              _ZN7cocos2d8CCString16createWithFormatEPKcz; cocos2d::CCString::createWithFormat(char const*,...) ; +0x26, 0x485c76\nBL              _ZNK7cocos2d8CCString10getCStringEv; cocos2d::CCString::getCString(void) ; +0x2a, 0x485c7a\nSTR             R4, [SP,#0x1C+var_14]                                  ; +0x2e, 0x485c7e\nSTR             R4, [SP,#0x1C+var_10]                                  ; +0x30, 0x485c80\nSTR             R4, [SP,#0x1C+var_C]                                   ; +0x32, 0x485c82\nADD             R4, SP, #0x1C+var_14                                   ; +0x34, 0x485c84\nMOV             R7, R0                                                 ; +0x36, 0x485c86\nBLX             strlen                                                 ; +0x38, 0x485c88\nMOV             R1, R7                                                 ; +0x3c, 0x485c8c\nMOV             R2, R0                                                 ; +0x3e, 0x485c8e\nMOV             R0, R4                                                 ; +0x40, 0x485c90\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEPKcj; std::string::__init(char const*,uint) ; +0x42, 0x485c92\nLDR             R3, =(aUnlimited - 0x485CA2); \"Unlimited\"              ; +0x46, 0x485c96\nLDR             R1, =(aMaxObjects - 0x485CA8); \"Max Objects\"           ; +0x48, 0x485c98\nADD.W           R0, R5, #0x13C; int                                    ; +0x4a, 0x485c9a\nADD             R3, PC; \"Unlimited\"                                    ; +0x4e, 0x485c9e\nSTR             R3, [SP,#0x1C+var_1C]; int                             ; +0x50, 0x485ca0\nLDR             R3, flt_485CF0                                         ; +0x52, 0x485ca2\nADD             R1, PC; \"Max Objects\"                                  ; +0x54, 0x485ca4\nMOV             R2, R4; int                                            ; +0x56, 0x485ca6\nSTR             R3, [SP,#0x1C+var_18]; float                           ; +0x58, 0x485ca8\nLDR             R3, =(aCancel - 0x485CB0); \"Cancel\"                    ; +0x5a, 0x485caa\nADD             R3, PC; \"Cancel\"                                       ; +0x5c, 0x485cac\nBL              _ZN12FLAlertLayer6createEP20FLAlertLayerProtocolPKcNSt6__ndk112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEES3_S3_f; FLAlertLayer::create(FLAlertLayerProtocol *,char const*,std::string,char const*,char const*,float) ; +0x5e, 0x485cae\nMOV             R5, R0                                                 ; +0x62, 0x485cb2\nMOV             R0, R4                                                 ; +0x64, 0x485cb4\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x66, 0x485cb6\nLDR             R3, [R5]                                               ; +0x6a, 0x485cba\nMOV             R0, R5                                                 ; +0x6c, 0x485cbc\nMOVS            R1, #0x7E ; '~'                                        ; +0x6e, 0x485cbe\nLDR             R3, [R3,#0x24]                                         ; +0x70, 0x485cc0\nBLX             R3                                                     ; +0x72, 0x485cc2\nLDR             R3, [R5]                                               ; +0x74, 0x485cc4\nMOV             R0, R5                                                 ; +0x76, 0x485cc6\nLDR.W           R3, [R3,#0x290]                                        ; +0x78, 0x485cc8\nBLX             R3                                                     ; +0x7c, 0x485ccc\nB               loc_485CDA                                             ; +0x7e, 0x485cce\nMOV             R0, R4                                                 ; +0x80, 0x485cd0\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x82, 0x485cd2\nBL              __cxa_end_cleanup                                      ; +0x86, 0x485cd6\nLDR             R2, [SP,#0x1C+var_8]                                   ; +0x8a, 0x485cda\nLDR             R3, [R6]                                               ; +0x8c, 0x485cdc\nCMP             R2, R3                                                 ; +0x8e, 0x485cde\nBEQ             loc_485CE6                                             ; +0x90, 0x485ce0\nBLX             __stack_chk_fail                                       ; +0x92, 0x485ce2\nADD             SP, SP, #0x1C                                          ; +0x96, 0x485ce6\nPOP             {R4-R7,PC}                                             ; +0x98, 0x485ce8", "xrefs": ["LevelEditorLayer::createObjectsFromString @ 0x46e810", "EditorUI::onCreate @ 0x48783e", "EditorUI::doPasteObjects @ 0x6f3260", "EditorUI::onDuplicate @ 0x6f39ce"], "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"}