//
// sub_BC89C from 0xbc89c to 0xbc9b0 (276 bytes)
//
// 1 xrefs:
// > sub_BC9B0 @ 0xbca08
//
// 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
//
void sub_BC89C()
{
float *v0; // x19
_DWORD *v1; // x21
__int64 v2; // x0
int v3; // w8
char v4; // nf
char v5; // vf
int i; // w2
int v7; // w22
bool v8; // zf
__int64 v9; // x8
__int64 v10; // x9
__int64 v11; // x0
__int64 v12; // x8
__int64 v13; // x9
float v14; // s0
float v15; // s1
float v16; // s2
float v17; // s17
float v18; // s0
float v19; // s3
float v20; // s4
float v21; // s2
float v22; // s3
float v23; // s5
float v24; // s4
float v25; // s1
float v26; // s6
float v27; // s7
float v28; // s5
float v29; // s6
float *v30; // x13
__int64 v31; // x9
int v32; // w15
int v33; // w14
int v34; // w17
int v35; // w16
int v36; // w1
float v37; // s0
float v38; // s2
float v39; // s3
float v40; // s4
__int64 v41; // x12
int v42; // w11
int v43; // w13
v2 = sub_BDBF8();
if ( v4 != v5 )
{
i = 2;
}
else
{
v2 = sub_BC120(v2, v0);
for ( i = 8; ; i = v7 )
{
v7 = 4 * i;
if ( 4 * i >= 2 * *v1 )
break;
v2 = sub_BDC5C(v2);
}
v3 = 2 * *v1;
}
v8 = v3 == 4 * i;
v9 = i;
v10 = 0;
if ( v8 )
{
v11 = sub_BDC48(v2);
while ( v13 < v12 )
{
v14 = sub_BDB7C(v11);
v17 = v16 + v14;
v18 = v14 - v16;
v21 = v20 + v19;
v22 = v19 - v20;
v24 = (float)-v15 - v23;
v25 = v23 - v15;
v28 = v27 + v26;
v29 = v26 - v27;
*(v30 - 1) = v21 + v17;
v13 = v31 + 2;
*v30 = v24 - v28;
v0[v32] = v17 - v21;
v0[(int)v11] = v28 + v24;
v0[v33] = v18 - v29;
v0[v34] = v25 - v22;
v0[v35] = v29 + v18;
v0[v36] = v22 + v25;
}
}
else
{
while ( v10 < v9 )
{
v37 = sub_BDBB4(v2);
*(float *)(v41 + 4) = (float)-v38 - v40;
v0[v42] = v37;
v0[v43] = v39 - v38;
}
}
}