{"type": "func", "start": 8440840, "end": 8441198, "name": "DS_Dictionary::loadRootSubDictFromFile", "pseudocode": "// \n// DS_Dictionary::loadRootSubDictFromFile from 0x80cc08 to 0x80cd6e (358 bytes)\n// \n// 4 xrefs:\n// > CCAnimateFrameCache::addSpriteFramesWithFile @ 0x3c46da\n// > CCAnimateFrameCache::addCustomSpriteFramesWithFile @ 0x3c4bca\n// > CCContentManager::addDict @ 0x80a19e\n// > CCContentManager::addDictDS @ 0x80a24e\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 12:01:33 +0000\n// \n\nint __fastcall DS_Dictionary::loadRootSubDictFromFile(DS_Dictionary *this, char *a2)\n{\n  int v4; // r2\n  int v5; // r5\n  cocos2d::CCFileUtils *v6; // r0\n  _DWORD *v7; // r3\n  int v8; // r0\n  cocos2d::CCFileUtils *v9; // r0\n  int v10; // r0\n  char *v11; // r1\n  int v12; // r6\n  cocos2d::CCFileUtils *v13; // r0\n  int v14; // r0\n  char *v15; // r1\n  int v16; // r5\n  int v18; // r6\n  _DWORD v19[4]; // [sp+8h] [bp-44h] BYREF\n  int v20; // [sp+18h] [bp-34h] BYREF\n  int v21; // [sp+1Ch] [bp-30h] BYREF\n  char v22; // [sp+20h] [bp-2Ch] BYREF\n  char v23; // [sp+21h] [bp-2Bh] BYREF\n  char *v24; // [sp+28h] [bp-24h]\n  _DWORD v25[3]; // [sp+2Ch] [bp-20h] BYREF\n  _DWORD v26[3]; // [sp+38h] [bp-14h] BYREF\n\n  v4 = *((_DWORD *)this + 50);\n  while ( 1 )\n  {\n    v5 = *((_DWORD *)this + 51);\n    if ( v4 == v5 )\n      break;\n    *((_DWORD *)this + 51) = v5 - 4;\n  }\n  v6 = (cocos2d::CCFileUtils *)pugi::xml_node::xml_node((pugi::xml_node *)v25);\n  v7 = *((_DWORD **)this + 51);\n  if ( (unsigned int)v7 >= *((_DWORD *)this + 52) )\n  {\n    std::vector<pugi::xml_node>::__push_back_slow_path<pugi::xml_node>((int *)this + 50, v25);\n  }\n  else\n  {\n    if ( v7 )\n      *v7 = v25[0];\n    *((_DWORD *)this + 51) += 4;\n  }\n  v8 = cocos2d::CCFileUtils::sharedFileUtils(v6);\n  v9 = (cocos2d::CCFileUtils *)(*(int (__fastcall **)(char *, int, char *, _DWORD))(*(_DWORD *)v8 + 24))(\n                                 &v22,\n                                 v8,\n                                 a2,\n                                 0);\n  v20 = 0;\n  v10 = cocos2d::CCFileUtils::sharedFileUtils(v9);\n  if ( (v22 & 1) != 0 )\n    v11 = v24;\n  else\n    v11 = &v23;\n  v12 = (*(int (__fastcall **)(int, char *, __int16 *, int *))(*(_DWORD *)v10 + 16))(v10, v11, &a1i2r3e45s789g[3], &v20);\n  pugi::xml_document::load_buffer((int)v25, this, v12, v20, 116, 0);\n  if ( !pugi::xml_parse_result::operator bool(v25) || !v12 )\n  {\n    FileOperation::getFilePath((FileOperation *)v26);\n    v13 = (cocos2d::CCFileUtils *)std::string::append(v26, a2);\n    v20 = 0;\n    v14 = cocos2d::CCFileUtils::sharedFileUtils(v13);\n    if ( (v26[0] & 1) != 0 )\n      v15 = (char *)v26[2];\n    else\n      v15 = (char *)v26 + 1;\n    v12 = (*(int (__fastcall **)(int, char *, __int16 *, int *))(*(_DWORD *)v14 + 16))(\n            v14,\n            v15,\n            &a1i2r3e45s789g[3],\n            &v20);\n    pugi::xml_document::load_buffer((int)v19, this, v12, v20, 116, 0);\n    v25[0] = v19[0];\n    v25[1] = v19[1];\n    v25[2] = v19[2];\n    std::string::~string((int)v26);\n  }\n  v16 = pugi::xml_parse_result::operator bool(v25);\n  if ( v16 )\n  {\n    if ( v12 )\n    {\n      v18 = *((_DWORD *)this + 51);\n      v21 = pugi::xml_node::child(this, \"plist\");\n      *(_DWORD *)(v18 - 4) = pugi::xml_node::child((pugi::xml_node *)&v21, \"dict\");\n      DS_Dictionary::checkCompatibility(this);\n    }\n    else\n    {\n      v16 = 0;\n    }\n  }\n  std::string::~string((int)&v22);\n  return v16;\n}", "assembly": "; \n; DS_Dictionary::loadRootSubDictFromFile from 0x80cc08 to 0x80cd6e (358 bytes)\n; \n; 4 xrefs:\n; > CCAnimateFrameCache::addSpriteFramesWithFile @ 0x3c46da\n; > CCAnimateFrameCache::addCustomSpriteFramesWithFile @ 0x3c4bca\n; > CCContentManager::addDict @ 0x80a19e\n; > CCContentManager::addDictDS @ 0x80a24e\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 12:01:33 +0000\n; \nLDR             R3, =(__stack_chk_guard_ptr - 0x80CC12)                ; +0x0, 0x80cc08\nPUSH.W          {R4-R11,LR}                                            ; +0x2, 0x80cc0a\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0x6, 0x80cc0e\nLDR             R3, [R3]; __stack_chk_guard                            ; +0x8, 0x80cc10\nSUB             SP, SP, #0x4C; int                                     ; +0xa, 0x80cc12\nMOV             R4, R0                                                 ; +0xc, 0x80cc14\nLDR             R2, [R3]                                               ; +0xe, 0x80cc16\nMOV             R7, R1                                                 ; +0x10, 0x80cc18\nMOV             R8, R3                                                 ; +0x12, 0x80cc1a\nSTR             R2, [SP,#0x4C+var_8]                                   ; +0x14, 0x80cc1c\nLDR.W           R2, [R0,#0xC8]                                         ; +0x16, 0x80cc1e\nLDR.W           R5, [R4,#0xCC]                                         ; +0x1a, 0x80cc22\nCMP             R2, R5                                                 ; +0x1e, 0x80cc26\nBEQ             loc_80CC32                                             ; +0x20, 0x80cc28\nSUBS            R5, #4                                                 ; +0x22, 0x80cc2a\nSTR.W           R5, [R4,#0xCC]                                         ; +0x24, 0x80cc2c\nB               loc_80CC22                                             ; +0x28, 0x80cc30\nADD             R5, SP, #0x4C+var_20                                   ; +0x2a, 0x80cc32\nMOV             R0, R5; this                                           ; +0x2c, 0x80cc34\nBL              _ZN4pugi8xml_nodeC1Ev; pugi::xml_node::xml_node(void)  ; +0x2e, 0x80cc36\nLDR.W           R3, [R4,#0xCC]                                         ; +0x32, 0x80cc3a\nLDR.W           R2, [R4,#0xD0]                                         ; +0x36, 0x80cc3e\nCMP             R3, R2                                                 ; +0x3a, 0x80cc42\nBCS             loc_80CC58                                             ; +0x3c, 0x80cc44\nCBZ             R3, loc_80CC4C                                         ; +0x3e, 0x80cc46\nLDR             R2, [SP,#0x4C+var_20]                                  ; +0x40, 0x80cc48\nSTR             R2, [R3]                                               ; +0x42, 0x80cc4a\nLDR.W           R3, [R4,#0xCC]                                         ; +0x44, 0x80cc4c\nADDS            R3, #4                                                 ; +0x48, 0x80cc50\nSTR.W           R3, [R4,#0xCC]                                         ; +0x4a, 0x80cc52\nB               loc_80CC62                                             ; +0x4e, 0x80cc56\nADD.W           R0, R4, #0xC8                                          ; +0x50, 0x80cc58\nMOV             R1, R5                                                 ; +0x54, 0x80cc5c\nBL              _ZNSt6__ndk16vectorIN4pugi8xml_nodeENS_9allocatorIS2_EEE21__push_back_slow_pathIS2_EEvOT_; std::vector<pugi::xml_node>::__push_back_slow_path<pugi::xml_node>(pugi::xml_node &&) ; +0x56, 0x80cc5e\nBL              _ZN7cocos2d11CCFileUtils15sharedFileUtilsEv; cocos2d::CCFileUtils::sharedFileUtils(void) ; +0x5a, 0x80cc62\nADD.W           R9, SP, #0x4C+var_2C                                   ; +0x5e, 0x80cc66\nMOV             R2, R7                                                 ; +0x62, 0x80cc6a\nADD.W           R11, SP, #0x4C+var_34                                  ; +0x64, 0x80cc6c\nLDR             R3, [R0]                                               ; +0x68, 0x80cc70\nMOV             R1, R0                                                 ; +0x6a, 0x80cc72\nMOV             R0, R9                                                 ; +0x6c, 0x80cc74\nLDR             R6, [R3,#0x18]                                         ; +0x6e, 0x80cc76\nMOVS            R3, #0                                                 ; +0x70, 0x80cc78\nBLX             R6                                                     ; +0x72, 0x80cc7a\nMOVS            R3, #0                                                 ; +0x74, 0x80cc7c\nSTR             R3, [SP,#0x4C+var_34]                                  ; +0x76, 0x80cc7e\nBL              _ZN7cocos2d11CCFileUtils15sharedFileUtilsEv; cocos2d::CCFileUtils::sharedFileUtils(void) ; +0x78, 0x80cc80\nLDR             R2, =(a1i2r3e45s789g+6 - 0x80CC8A); \"r3e45s789g\"       ; +0x7c, 0x80cc84\nADD             R2, PC; \"r3e45s789g\"                                   ; +0x7e, 0x80cc86\nLDR             R3, [R0]                                               ; +0x80, 0x80cc88\nLDR             R6, [R3,#0x10]                                         ; +0x82, 0x80cc8a\nLDRB.W          R3, [SP,#0x4C+var_2C]                                  ; +0x84, 0x80cc8c\nLSLS            R3, R3, #0x1F                                          ; +0x88, 0x80cc90\nMOV             R3, R11                                                ; +0x8a, 0x80cc92\nITE PL                                                                 ; +0x8c, 0x80cc94\nADDPL.W         R1, SP, #0x4C+var_2B                                   ; +0x8e, 0x80cc96\nLDRMI           R1, [SP,#0x4C+var_24]                                  ; +0x92, 0x80cc9a\nBLX             R6                                                     ; +0x94, 0x80cc9c\nMOVS            R1, #0x74 ; 't'                                        ; +0x96, 0x80cc9e\nMOVS            R3, #0                                                 ; +0x98, 0x80cca0\nSTMEA.W         SP, {R1,R3}                                            ; +0x9a, 0x80cca2\nMOV             R1, R4; this                                           ; +0x9e, 0x80cca6\nLDR             R3, [SP,#0x4C+var_34]; int                             ; +0xa0, 0x80cca8\nMOV             R6, R0                                                 ; +0xa2, 0x80ccaa\nMOV             R0, R5; int                                            ; +0xa4, 0x80ccac\nMOV             R2, R6; int                                            ; +0xa6, 0x80ccae\nBL              _ZN4pugi12xml_document11load_bufferEPKvjjNS_12xml_encodingE; pugi::xml_document::load_buffer(void const*,uint,uint,pugi::xml_encoding) ; +0xa8, 0x80ccb0\nMOV             R0, R5                                                 ; +0xac, 0x80ccb4\nBL              _ZNK4pugi16xml_parse_resultcvbEv; pugi::xml_parse_result::operator bool(void) ; +0xae, 0x80ccb6\nCBZ             R0, loc_80CCBE                                         ; +0xb2, 0x80ccba\nCBNZ            R6, loc_80CD14                                         ; +0xb4, 0x80ccbc\nADD.W           R10, SP, #0x4C+var_14                                  ; +0xb6, 0x80ccbe\nMOV             R0, R10; this                                          ; +0xba, 0x80ccc2\nBL              _ZN13FileOperation11getFilePathEv; FileOperation::getFilePath(void) ; +0xbc, 0x80ccc4\nMOV             R1, R7; char *                                         ; +0xc0, 0x80ccc8\nMOV             R0, R10; int                                           ; +0xc2, 0x80ccca\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6appendEPKc; std::string::append(char const*) ; +0xc4, 0x80cccc\nMOVS            R3, #0                                                 ; +0xc8, 0x80ccd0\nSTR             R3, [SP,#0x4C+var_34]                                  ; +0xca, 0x80ccd2\nBL              _ZN7cocos2d11CCFileUtils15sharedFileUtilsEv; cocos2d::CCFileUtils::sharedFileUtils(void) ; +0xcc, 0x80ccd4\nLDR             R3, [R0]                                               ; +0xd0, 0x80ccd8\nLDR             R6, [R3,#0x10]                                         ; +0xd2, 0x80ccda\nLDRB.W          R3, [SP,#0x4C+var_14]                                  ; +0xd4, 0x80ccdc\nLSLS            R3, R3, #0x1F                                          ; +0xd8, 0x80cce0\nBPL             loc_80CD38                                             ; +0xda, 0x80cce2\nLDR             R1, [SP,#0x4C+var_C]                                   ; +0xdc, 0x80cce4\nLDR             R2, =(a1i2r3e45s789g+6 - 0x80CCF0); \"r3e45s789g\"       ; +0xde, 0x80cce6\nMOV             R3, R11                                                ; +0xe0, 0x80cce8\nADD             R7, SP, #0x4C+var_44                                   ; +0xe2, 0x80ccea\nADD             R2, PC; \"r3e45s789g\"                                   ; +0xe4, 0x80ccec\nBLX             R6                                                     ; +0xe6, 0x80ccee\nMOVS            R2, #0x74 ; 't'                                        ; +0xe8, 0x80ccf0\nMOVS            R3, #0                                                 ; +0xea, 0x80ccf2\nMOV             R1, R4; this                                           ; +0xec, 0x80ccf4\nSTMEA.W         SP, {R2,R3}                                            ; +0xee, 0x80ccf6\nLDR             R3, [SP,#0x4C+var_34]; int                             ; +0xf2, 0x80ccfa\nMOV             R6, R0                                                 ; +0xf4, 0x80ccfc\nMOV             R0, R7; int                                            ; +0xf6, 0x80ccfe\nMOV             R2, R6; int                                            ; +0xf8, 0x80cd00\nBL              _ZN4pugi12xml_document11load_bufferEPKvjjNS_12xml_encodingE; pugi::xml_document::load_buffer(void const*,uint,uint,pugi::xml_encoding) ; +0xfa, 0x80cd02\nLDM.W           R7, {R0-R2}                                            ; +0xfe, 0x80cd06\nSTM.W           R5, {R0-R2}                                            ; +0x102, 0x80cd0a\nMOV             R0, R10                                                ; +0x106, 0x80cd0e\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x108, 0x80cd10\nMOV             R0, R5                                                 ; +0x10c, 0x80cd14\nBL              _ZNK4pugi16xml_parse_resultcvbEv; pugi::xml_parse_result::operator bool(void) ; +0x10e, 0x80cd16\nMOV             R5, R0                                                 ; +0x112, 0x80cd1a\nCBZ             R0, loc_80CD22                                         ; +0x114, 0x80cd1c\nCBNZ            R6, loc_80CD3E                                         ; +0x116, 0x80cd1e\nMOV             R5, R6                                                 ; +0x118, 0x80cd20\nMOV             R0, R9                                                 ; +0x11a, 0x80cd22\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x11c, 0x80cd24\nLDR             R2, [SP,#0x4C+var_8]                                   ; +0x120, 0x80cd28\nLDR.W           R3, [R8]                                               ; +0x122, 0x80cd2a\nMOV             R0, R5                                                 ; +0x126, 0x80cd2e\nCMP             R2, R3                                                 ; +0x128, 0x80cd30\nBEQ             loc_80CD68                                             ; +0x12a, 0x80cd32\nBLX             __stack_chk_fail                                       ; +0x12c, 0x80cd34\nADD.W           R1, SP, #0x4C+var_13                                   ; +0x130, 0x80cd38\nB               loc_80CCE6                                             ; +0x134, 0x80cd3c\nLDR             R1, =(aPlist_0 - 0x80CD4A); \"plist\"                    ; +0x136, 0x80cd3e\nMOV             R0, R4; this                                           ; +0x138, 0x80cd40\nLDR.W           R6, [R4,#0xCC]                                         ; +0x13a, 0x80cd42\nADD             R1, PC; \"plist\"                                        ; +0x13e, 0x80cd46\nBL              _ZNK4pugi8xml_node5childEPKc; pugi::xml_node::child(char const*) ; +0x140, 0x80cd48\nADD             R3, SP, #0x4C+var_4                                    ; +0x144, 0x80cd4c\nLDR             R1, =(aDict_1 - 0x80CD54); \"dict\"                      ; +0x146, 0x80cd4e\nADD             R1, PC; \"dict\"                                         ; +0x148, 0x80cd50\nSTR.W           R0, [R3,#-0x2C]!                                       ; +0x14a, 0x80cd52\nMOV             R0, R3; this                                           ; +0x14e, 0x80cd56\nBL              _ZNK4pugi8xml_node5childEPKc; pugi::xml_node::child(char const*) ; +0x150, 0x80cd58\nSTR.W           R0, [R6,#-4]                                           ; +0x154, 0x80cd5c\nMOV             R0, R4; this                                           ; +0x158, 0x80cd60\nBL              _ZN13DS_Dictionary18checkCompatibilityEv; DS_Dictionary::checkCompatibility(void) ; +0x15a, 0x80cd62\nB               loc_80CD22                                             ; +0x15e, 0x80cd66\nADD             SP, SP, #0x4C ; 'L'                                    ; +0x160, 0x80cd68\nPOP.W           {R4-R11,PC}                                            ; +0x162, 0x80cd6a", "xrefs": ["CCAnimateFrameCache::addSpriteFramesWithFile @ 0x3c46da", "CCAnimateFrameCache::addCustomSpriteFramesWithFile @ 0x3c4bca", "CCContentManager::addDict @ 0x80a19e", "CCContentManager::addDictDS @ 0x80a24e"], "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"}