// // sub_1004BD248 from 0x1004bd248 to 0x1004bd3d0 (392 bytes) // // 1 xrefs: // > sub_10043E934 @ 0x10043ea38 // // 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 // __int64 __fastcall sub_1004BD248(__int64 a1, unsigned int a2, __int64 a3) { __int64 result; // x0 unsigned __int64 *v5; // x19 int v6; // w21 int v7; // w3 unsigned int v8; // w2 int v9; // [xsp+Ch] [xbp-34h] BYREF __int64 v10; // [xsp+10h] [xbp-30h] BYREF int v11; // [xsp+1Ch] [xbp-24h] BYREF if ( a2 > 3 ) return 31; *(_QWORD *)a1 = a3; *(_DWORD *)(a1 + 16) = a2; v5 = (unsigned __int64 *)(a1 + 8); if ( *(_QWORD *)(a1 + 8) ) return 0; result = sub_1004BC240(*(_QWORD *)(a3 + 69128), &v11); if ( !(_DWORD)result ) { if ( v11 < 1 ) { return 54; } else { v6 = 0; while ( 1 ) { v10 = 0; if ( !(unsigned int)sub_1004BC49C(*(_QWORD *)(*(_QWORD *)a1 + 69128LL), v6, &v9) && !(unsigned int)sub_1004BB900(*(_QWORD *)(*(_QWORD *)a1 + 69128LL), v9, &v10) && *(_DWORD *)(v10 + 24) == 19 ) { break; } if ( ++v6 >= v11 ) return 54; } result = sub_1004BC664(*(_QWORD *)(*(_QWORD *)a1 + 69128LL), v10, 0, v5); if ( !(_DWORD)result ) { v7 = *(_DWORD *)(*(_QWORD *)a1 + 70460LL); v8 = 1; switch ( v7 ) { case 2: break; case 3: v8 = 2; break; case 4: case 5: case 6: v8 = *(_DWORD *)(*(_QWORD *)a1 + 70460LL); break; case 7: v8 = 8; break; case 8: v8 = 12; break; default: if ( v7 == 1000 ) v8 = 2; else v8 = 0; break; } sub_1004A16F0(*(_QWORD *)(a1 + 8), 0, v8, v7); return sub_1004A79E0(*v5, 0xCu, -80.0); } } } return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source