//
// PlayerObject::playerDestroyed from 0x1404f5ff0 to 0x1404f60dc (236 bytes)
//
// 4 xrefs:
// > LevelEditorLayer::postUpdate @ 0x140400a77
// > PlayLayer::destroyPlayer @ 0x140512732
// > PlayLayer::destroyPlayer @ 0x14051276d
// > ??> @ 0x14092a158
//
// This function is hookable on this platform (idp: pc, 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:33:20 +0000
//
__int64 __fastcall PlayerObject::playerDestroyed(__int64 a1, char a2)
{
__int64 v4; // rax
cocos2d::CCNode *v5; // rcx
if ( *(_BYTE *)(a1 + 2500) )
PlayerObject::fadeOutStreak2(a1);
PlayerObject::stopDashing(a1);
*(_BYTE *)(a1 + 2504) = 1;
*(_WORD *)(a1 + 1840) = 0;
*(_BYTE *)(a1 + 1648) = 0;
*(_DWORD *)(a1 + 1832) = 0;
PlayerObject::stopParticles(a1);
v4 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 200LL))(a1);
cocos2d::CCPoint::operator=(a1 + 1232, v4);
v5 = *(cocos2d::CCNode **)(a1 + 3096);
if ( v5 )
{
cocos2d::CCNode::stopAllActions(v5);
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 3096) + 336LL))(*(_QWORD *)(a1 + 3096), 0);
}
PlayerObject::toggleGhostEffect(a1, 0);
PlayerObject::disableSwingFire(a1);
if ( !*(_BYTE *)(a1 + 2028) || a2 || *(_BYTE *)(a1 + 1843) )
return (*(__int64 (__fastcall **)(__int64, _QWORD))(*(_QWORD *)(a1 + 320) + 40LL))(a1 + 320, 0);
else
return PlayerObject::playDeathEffect((__int64 *)a1);
}