//
// PlayLayer::dtDeathIsBarren from 0xc36588 to 0xc367a8 (544 bytes)
//
// 2 xrefs:
// > PlayLayer::tryShowDeathMarkers @ 0xc37738
// > ??> @ 0x4e658
//
// 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 13:04:51 +0000
//
__int64 __fastcall PlayLayer::dtDeathIsBarren(PlayLayer *this, int a2, int a3, unsigned __int8 a4, unsigned __int8 a5)
{
int v6; // w25
int v9; // w24
__int64 v10; // x0
unsigned __int64 v11; // x27
__int64 i; // x26
int v13; // w25
float v14; // s8
float v15; // s0
__int64 v16; // x0
unsigned __int64 v17; // x26
__int64 v18; // x25
__int64 v19; // x2
int v20; // w24
int v21; // w1
float v22; // s8
float v23; // s0
float v25; // s0
float v26; // s8
float v27; // s0
float v28; // s0
float v29; // s0
float v30; // s8
float v31; // s0
float v32; // s0
_BYTE v33[16]; // [xsp+78h] [xbp+78h] BYREF
v6 = a5;
v9 = a4;
PlayLayer::dtMarkerVisibleRect(this, (cocos2d::CCRect *)v33);
if ( v6 )
{
v10 = *((_QWORD *)this + 1802);
v11 = 9;
for ( i = 0; v11 <= (*((_QWORD *)this + 1803) - v10) >> 2; i += 36 )
{
v13 = *(_DWORD *)(v10 + i + 4);
v14 = (float)(10 * *(_DWORD *)(v10 + i)) + 5.0;
cocos2d::CCRect::getMinX((cocos2d::CCRect *)v33);
if ( v14 >= v15 )
{
cocos2d::CCRect::getMaxX((cocos2d::CCRect *)v33);
if ( v14 <= v25 )
{
v26 = (float)(10 * v13) + 5.0;
cocos2d::CCRect::getMinY((cocos2d::CCRect *)v33);
if ( v26 >= v27 )
{
cocos2d::CCRect::getMaxY((cocos2d::CCRect *)v33);
if ( v26 <= v28 )
return 0;
}
}
}
v10 = *((_QWORD *)this + 1802);
v11 += 9LL;
}
}
if ( !v9 )
return 1;
v16 = *((_QWORD *)this + 1805);
v17 = 4;
v18 = 4;
v19 = *((_QWORD *)this + 1806) - v16;
if ( (unsigned __int64)(v19 >> 2) < 4 )
return 1;
while ( 1 )
{
v20 = *(_DWORD *)(v16 + v18);
v21 = *(_DWORD *)(v16 + v18 - 4);
if ( v21 != a2 || v20 != a3 )
break;
if ( *(int *)(v16 + v18 + 4) > 2 )
return 0;
v18 += 16;
LABEL_10:
v17 += 4LL;
if ( v17 > v19 >> 2 )
return 1;
}
v22 = (float)(10 * v21) + 5.0;
cocos2d::CCRect::getMinX((cocos2d::CCRect *)v33);
if ( v22 < v23
|| (cocos2d::CCRect::getMaxX((cocos2d::CCRect *)v33), v22 > v29)
|| (v30 = (float)(10 * v20) + 5.0, cocos2d::CCRect::getMinY((cocos2d::CCRect *)v33), v30 < v31)
|| (cocos2d::CCRect::getMaxY((cocos2d::CCRect *)v33), v30 > v32) )
{
v16 = *((_QWORD *)this + 1805);
v18 += 16;
v19 = *((_QWORD *)this + 1806) - v16;
goto LABEL_10;
}
return 0;
}