// // cocos2d::CCPrettyPrinter::visit_2 from 0x1004ae7e0 to 0x1004aec16 (1078 bytes) // // 1 xrefs: // > @ 0x100b55b98 // // This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True! // // Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings // Generated at Fri, 27 Nov 2026 12:30:58 +0000 // __int64 __fastcall cocos2d::CCPrettyPrinter::visit_2(__int64 a1, __int64 a2) { __int64 v3; // r12 unsigned int v4; // edx const std::string::value_type *v5; // rsi std::string::size_type v6; // rdx int v7; // eax bool v8; // zf std::string *v9; // r13 int i; // r15d unsigned int *v11; // rcx __int64 v12; // rdx std::string *v13; // rsi _QWORD *v14; // r15 int v15; // ebx __int64 v16; // r12 std::string::value_type *v17; // rdx int v18; // eax int v19; // r15d const std::string::value_type *v20; // rsi std::string::size_type v21; // rdx int v22; // eax int v23; // r14d unsigned int v24; // edx std::string::value_type *v25; // rsi std::string::size_type v26; // rdx _QWORD *v28; // [rsp+0h] [rbp-100h] unsigned __int64 v29; // [rsp+8h] [rbp-F8h] __int64 (__fastcall **v30)(); // [rsp+10h] [rbp-F0h] BYREF int v31; // [rsp+18h] [rbp-E8h] std::string v32[2]; // [rsp+20h] [rbp-E0h] BYREF std::string::value_type v33[16]; // [rsp+50h] [rbp-B0h] BYREF void *__p; // [rsp+60h] [rbp-A0h] __int64 v35; // [rsp+70h] [rbp-90h] std::string::value_type *v36; // [rsp+78h] [rbp-88h] std::string *v37; // [rsp+80h] [rbp-80h] std::string *v38; // [rsp+88h] [rbp-78h] std::string::value_type __s[16]; // [rsp+90h] [rbp-70h] BYREF __int128 v40; // [rsp+A0h] [rbp-60h] __int128 v41; // [rsp+B0h] [rbp-50h] __int16 v42; // [rsp+C0h] [rbp-40h] v3 = a1; v38 = (std::string *)(a1 + 40); std::string::append((std::string *)(a1 + 40), "\n"); v4 = *(unsigned __int8 *)(a1 + 16); v5 = (const std::string::value_type *)(a1 + 17); v36 = (std::string::value_type *)(a1 + 17); if ( (v4 & 1) != 0 ) { v5 = *(const std::string::value_type **)(a1 + 32); v6 = *(_QWORD *)(a1 + 24); } else { v6 = v4 >> 1; } std::string::append(v38, v5, v6); std::string::append(v38, "\n"); v7 = *(_DWORD *)(a1 + 8) + 1; *(_DWORD *)(a1 + 8) = v7; v8 = (*(_BYTE *)(a1 + 16) & 1) == 0; v37 = (std::string *)(a1 + 16); if ( v8 ) { *v36 = 0; *(_BYTE *)(a1 + 16) = 0; v9 = v37; if ( v7 <= 0 ) goto LABEL_10; } else { **(_BYTE **)(a1 + 32) = 0; *(_QWORD *)(a1 + 24) = 0; v7 = *(_DWORD *)(a1 + 8); v9 = v37; if ( v7 <= 0 ) goto LABEL_10; } for ( i = 0; i < v7; ++i ) { std::string::append(v9, "\t"); v7 = *(_DWORD *)(a1 + 8); } LABEL_10: v41 = 0; v40 = 0; *(_OWORD *)__s = 0; v42 = 0; if ( !a2 ) goto LABEL_36; v11 = *(unsigned int **)(a2 + 56); v12 = *v11; v13 = v37; if ( *v11 ) { v35 = a1; v14 = *((_QWORD **)v11 + 2); v29 = (unsigned __int64)&v14[v12 - 1]; v15 = 0; while ( 1 ) { v16 = *v14; if ( !*v14 ) { LABEL_35: v3 = v35; v7 = *(_DWORD *)(v35 + 8); LABEL_36: v13 = v37; break; } v28 = v14; if ( v15 ) std::string::append(v38, "\n"); v17 = v36; if ( (*(_BYTE *)&v37->__r_.__value_.__s.0 & 1) != 0 ) v17 = *(std::string::value_type **)(v35 + 32); sprintf(__s, "%s%02d: ", v17, v15); std::string::append(v38, __s); v18 = *(_DWORD *)(v35 + 8); v30 = &off_100B55B58; memset(v32, 0, sizeof(v32)); v31 = v18; if ( v18 > 0 ) { v19 = 0; do { std::string::append(v32, "\t"); ++v19; } while ( v19 < v31 ); } (*(void (__fastcall **)(__int64, __int64 (__fastcall ***)()))(*(_QWORD *)v16 + 32LL))(v16, &v30); if ( (*(_BYTE *)&v32[1].__r_.__value_.__s.0 & 1) != 0 ) { sub_10001AD30(v33, v32[1].__r_.__value_.__l.__data_, v32[1].__r_.__value_.__l.__size_); } else { __p = v32[1].__r_.__value_.__l.__data_; *(_OWORD *)v33 = *(_OWORD *)&v32[1].__r_.__value_.__l.0; } if ( (v33[0] & 1) != 0 ) { v20 = (const std::string::value_type *)__p; v21 = *(_QWORD *)&v33[8]; } else { v21 = (unsigned __int8)v33[0] >> 1; v20 = &v33[1]; } std::string::append(v38, v20, v21); if ( (v33[0] & 1) != 0 ) { operator delete(__p); v30 = &off_100B55B58; if ( (*(_BYTE *)&v32[1].__r_.__value_.__s.0 & 1) == 0 ) { LABEL_30: if ( (*(_BYTE *)&v32[0].__r_.__value_.__s.0 & 1) != 0 ) goto LABEL_34; goto LABEL_13; } } else { v30 = &off_100B55B58; if ( (*(_BYTE *)&v32[1].__r_.__value_.__s.0 & 1) == 0 ) goto LABEL_30; } operator delete(v32[1].__r_.__value_.__l.__data_); if ( (*(_BYTE *)&v32[0].__r_.__value_.__s.0 & 1) != 0 ) LABEL_34: operator delete(v32[0].__r_.__value_.__l.__data_); LABEL_13: ++v15; v14 = v28 + 1; if ( (unsigned __int64)(v28 + 1) > v29 ) goto LABEL_35; } } v22 = v7 - 1; *(_DWORD *)(v3 + 8) = v22; if ( (*(_BYTE *)(v3 + 16) & 1) != 0 ) { **(_BYTE **)(v3 + 32) = 0; *(_QWORD *)(v3 + 24) = 0; if ( *(int *)(v3 + 8) <= 0 ) goto LABEL_43; LABEL_41: v23 = 0; do { std::string::append(v37, "\t"); ++v23; } while ( v23 < *(_DWORD *)(v3 + 8) ); goto LABEL_43; } *v36 = 0; v13->__r_.__value_.__s.0 = 0; if ( v22 > 0 ) goto LABEL_41; LABEL_43: std::string::append(v38, "\n"); v24 = *(unsigned __int8 *)(v3 + 16); if ( (v24 & 1) != 0 ) { v25 = *(std::string::value_type **)(v3 + 32); v26 = *(_QWORD *)(v3 + 24); } else { v26 = v24 >> 1; v25 = v36; } std::string::append(v38, v25, v26); std::string::append(v38, ""); return __stack_chk_guard; }
GD Web Decomp Icon

GD Web Decomp

Raw Source