//
// GJBaseGameLayer::checkCollisionBlocks from 0x100286d4c to 0x100286ef8 (428 bytes)
//
// 2 xrefs:
// > GJBaseGameLayer::updateCollisionBlocks @ 0x100286cd8
// > GJBaseGameLayer::updateCollisionBlocks @ 0x100286d14
//
// This function is hookable on this platform (idp: arm, 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 11:01:58 +0000
//
__int64 __fastcall GJBaseGameLayer::checkCollisionBlocks(_DWORD *a1, __int64 a2, _QWORD *a3, int a4)
{
int v8; // w25
__int64 v9; // x0
float v10; // s8
float v11; // s9
float v12; // s10
float v13; // s11
__int64 result; // x0
float *v15; // x22
__int64 v16; // x26
__int64 v17; // x27
__int64 v18; // x23
float v19; // s0
float *v20; // x24
_QWORD v21[2]; // [xsp+0h] [xbp-80h] BYREF
v8 = *(_DWORD *)(a2 + 916);
v9 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a2 + 1328LL))(a2);
sub_1000264D4(v21, v9);
v10 = sub_10002656C((float *)v21);
v11 = sub_1000265A0((__int64)v21);
v12 = sub_1000265A8((__int64)v21);
v13 = sub_1000265DC((__int64)v21);
result = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a2 + 1560LL))(a2);
if ( a4 >= 1 )
{
v15 = (float *)result;
v16 = 0;
v17 = 8LL * (unsigned int)a4;
do
{
v18 = *(_QWORD *)(*a3 + v16);
if ( (*(_BYTE *)(v18 + 650) & 1) == 0 && *(_DWORD *)(v18 + 1836) != a1[824] )
{
result = GameObject::getObjectRectPointer(*(_QWORD *)(*a3 + v16));
if ( v10 >= *(float *)result && (float)(*(float *)result + *(float *)(result + 8)) >= v11 )
{
v19 = *(float *)(result + 4);
if ( v12 >= v19 && (float)(v19 + *(float *)(result + 12)) >= v13 && *(_DWORD *)(v18 + 916) != v8 )
{
if ( (*(_BYTE *)(a2 + 744) & 1) == 0 && *(_BYTE *)(v18 + 744) != 1
|| (v20 = (float *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v18 + 1560LL))(v18),
result = OBB2D::overlaps1Way((__int64)v15, v20),
(_DWORD)result)
&& (result = OBB2D::overlaps1Way((__int64)v20, v15), (_DWORD)result) )
{
result = (*(__int64 (__fastcall **)(_DWORD *, _QWORD, _QWORD))(*(_QWORD *)a1 + 1224LL))(
a1,
*(unsigned int *)(a2 + 1680),
*(unsigned int *)(v18 + 1680));
}
}
}
}
v16 += 8;
}
while ( v17 != v16 );
}
return result;
}