// // sub_18006F980 from 0x18006f980 to 0x18006fb65 (485 bytes) // // 6 xrefs: // > sub_18006F980 @ 0x18006fb19 // > sub_18006FB70 @ 0x18006fc8b // > cocos2d::CCFileUtils::writeToFile @ 0x1800722db // > @ 0x18013ad44 // > @ 0x18013ad54 // > @ 0x1801b4194 // // This function is hookable on this platform! // // Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings // struct tinyxml2::XMLElement *__fastcall sub_18006F980(__int64 a1, tinyxml2::XMLDocument *a2) { struct tinyxml2::XMLElement *result; // rax tinyxml2::XMLNode *v5; // r15 __int64 v6; // rdi __int64 i; // r14 struct tinyxml2::XMLNode *v8; // rbx struct tinyxml2::XMLNode *v9; // rax __int64 v10; // rdi cocos2d::CCString *v11; // rbx tinyxml2::XMLNode *v12; // rdi std::string *CString; // rax struct tinyxml2::XMLNode *v14; // rax __int64 v15; // rbx struct tinyxml2::XMLElement *v16; // rax unsigned int *v17; // rbx __int64 v18; // rax _QWORD *v19; // rbx _QWORD *j; // rbp struct tinyxml2::XMLNode *v21; // rax __int64 v22; // rax result = tinyxml2::XMLDocument::NewElement(a2, "dict"); v5 = result; if ( a1 ) { v6 = *(_QWORD *)(a1 + 56); if ( v6 ) { for ( i = *(_QWORD *)(v6 + 288); ; i = *(_QWORD *)(i + 288) ) { v8 = tinyxml2::XMLDocument::NewElement(a2, "key"); tinyxml2::XMLNode::InsertEndChild(v5, v8); v9 = tinyxml2::XMLDocument::NewText(a2, (const char *)v6); tinyxml2::XMLNode::InsertEndChild(v8, v9); v10 = *(_QWORD *)(v6 + 264); v11 = (cocos2d::CCString *)_RTDynamicCast( v10, 0, &cocos2d::CCObject `RTTI Type Descriptor', &cocos2d::CCString `RTTI Type Descriptor', 0); if ( v11 ) { v12 = tinyxml2::XMLDocument::NewElement(a2, "string"); CString = cocos2d::CCString::getCString(v11); v14 = tinyxml2::XMLDocument::NewText(a2, CString->m_data.m_smallStorage._Elems); tinyxml2::XMLNode::InsertEndChild(v12, v14); } else { v15 = _RTDynamicCast( v10, 0, &cocos2d::CCObject `RTTI Type Descriptor', &cocos2d::CCArray `RTTI Type Descriptor', 0); if ( v15 ) { v16 = tinyxml2::XMLDocument::NewElement(a2, "array"); v17 = *(unsigned int **)(v15 + 56); v12 = v16; v18 = *v17; if ( (_DWORD)v18 ) { v19 = *((_QWORD **)v17 + 2); for ( j = &v19[v18 - 1]; v19 <= j; ++v19 ) { if ( !*v19 ) break; v21 = (struct tinyxml2::XMLNode *)sub_18006FB70(*v19, a2); if ( v21 ) tinyxml2::XMLNode::InsertEndChild(v12, v21); } } } else { v22 = _RTDynamicCast( v10, 0, &cocos2d::CCObject `RTTI Type Descriptor', &cocos2d::CCDictionary `RTTI Type Descriptor', 0); if ( !v22 ) goto LABEL_18; v12 = (tinyxml2::XMLNode *)sub_18006F980(v22, a2); } } if ( v12 ) tinyxml2::XMLNode::InsertEndChild(v5, v12); LABEL_18: v6 = i; if ( !i ) return v5; } } } return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source