//
// sub_766930 from 0x766930 to 0x766ab0 (384 bytes)
//
// 2 xrefs:
// > DeathHistogram::setSurvival @ 0x7680ec
// > DeathHistogram::setSurvival @ 0x7681e6
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:59:08 +0000
//
cocos2d::CCDrawNode *__fastcall sub_766930(cocos2d::CCDrawNode *a1, int a2)
{
float v2; // s0
float v3; // s1
float v6; // s19
float v7; // s16
int v8; // r4
float v9; // r2
float i; // s19
float v11; // r2
const char *v12; // r2
int v13; // r4
void (__fastcall *v14)(int, _BYTE *); // r11
_BYTE v16[8]; // [sp+Ch] [bp-8h] BYREF
_BYTE v17[8]; // [sp+14h] [bp+0h] BYREF
_DWORD v18[4]; // [sp+1Ch] [bp+8h] BYREF
_DWORD v19[4]; // [sp+2Ch] [bp+18h] BYREF
memset(v18, 0, 12);
v19[0] = 0;
v19[2] = 0;
v18[3] = 1065353216;
v19[1] = 1065353216;
v19[3] = 1065353216;
v6 = 35.0;
v7 = v3 - 4.0;
v8 = cocos2d::CCDrawNode::create(a1);
while ( v6 < v7 )
{
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v17, v2, v6);
if ( (float)(v6 + 3.0) <= v7 )
v9 = v6 + 3.0;
else
v9 = v3 - 4.0;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, v2, v9);
cocos2d::CCDrawNode::drawSegment(v8, v17, v16, 1069547520, v18);
v6 = v6 + 6.0;
}
for ( i = 35.0; i < v7; i = i + 6.0 )
{
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v17, v2, i);
if ( (float)(i + 3.0) <= v7 )
v11 = i + 3.0;
else
v11 = v3 - 4.0;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, v2, v11);
cocos2d::CCDrawNode::drawSegment(v8, v17, v16, 1056964608, v19);
}
(*(void (__fastcall **)(int, int))(*(_DWORD *)a2 + 228))(a2, v8);
v13 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)"You", "bigFont.fnt", v12);
(*(void (__fastcall **)(int, int))(*(_DWORD *)v13 + 80))(v13, 1050924810);
v14 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v13 + 92);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v17, v2, v3 + 4.0);
v14(v13, v17);
(*(void (__fastcall **)(int, int, int))(*(_DWORD *)a2 + 232))(a2, v13, 5);
DtLabelPlacer::boxFor((float *)a1, v13, v2, v3 + 4.0, 0.32);
return a1;
}