//
// PlayerObject::playerDestroyed from 0x100400b40 to 0x100400d36 (502 bytes)
//
// 3 xrefs:
// > PlayLayer::destroyPlayer @ 0x100087aeb
// > PlayLayer::destroyPlayer @ 0x100087b1a
// > LevelEditorLayer::postUpdate @ 0x1000c74ec
//
// 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 12:30:02 +0000
//
__int64 __fastcall PlayerObject::playerDestroyed(
__int64 a1,
unsigned __int8 a2,
__m128 a3,
__m128 a4,
double a5,
__m128 a6)
{
_OWORD *v7; // r15
__int64 v8; // rax
__int64 v9; // r15
_QWORD *v10; // rax
__int64 v11; // rdi
__int64 v12; // rdx
if ( *(_BYTE *)(a1 + 2420) == 1 && !cocos2d::CCNode::getActionByTag(*(_QWORD *)(a1 + 1920), 8) )
{
a3 = (__m128)0x3E4CCCCDu;
v7 = cocos2d::CCFadeOut::create((__m128)0x3E4CCCCDu);
v8 = cocos2d::CCCallFunc::create(*(_QWORD *)(a1 + 1920), HardStreak::stopStroke, 0);
v9 = sub_10039EB60((__int64)v7, v8, 0);
(*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v9 + 72LL))(v9, 8);
cocos2d::CCNode::runAction(*(_QWORD *)(a1 + 1920), v9);
}
PlayerObject::stopDashing(a1, a3, a4);
*(_BYTE *)(a1 + 2424) = 1;
*(_WORD *)(a1 + 1784) = 0;
*(_BYTE *)(a1 + 1640) = 0;
*(_DWORD *)(a1 + 1776) = 0;
if ( *(_BYTE *)(a1 + 1974) == 1 )
cocos2d::CCParticleSystem::stopSystem(*(_QWORD *)(a1 + 2160));
*(_BYTE *)(a1 + 1974) = 0;
cocos2d::CCParticleSystem::stopSystem(*(_QWORD *)(a1 + 2168));
cocos2d::CCParticleSystem::stopSystem(*(_QWORD *)(a1 + 2176));
cocos2d::CCParticleSystem::stopSystem(*(_QWORD *)(a1 + 2184));
cocos2d::CCParticleSystem::stopSystem(*(_QWORD *)(a1 + 2200));
v10 = (_QWORD *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a1 + 192LL))(a1);
sub_100278300((_QWORD *)(a1 + 1224), v10);
v11 = *(_QWORD *)(a1 + 3000);
if ( v11 )
{
cocos2d::CCNode::stopAllActions(v11);
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 3000) + 344LL))(*(_QWORD *)(a1 + 3000), 0);
}
PlayerObject::toggleGhostEffect(a1, 0);
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 1872) + 344LL))(*(_QWORD *)(a1 + 1872), 0);
cocos2d::CCNode::stopAllActions(*(_QWORD *)(a1 + 1872));
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 1880) + 344LL))(*(_QWORD *)(a1 + 1880), 0);
cocos2d::CCNode::stopAllActions(*(_QWORD *)(a1 + 1880));
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 1888) + 344LL))(*(_QWORD *)(a1 + 1888), 0);
cocos2d::CCNode::stopAllActions(*(_QWORD *)(a1 + 1888));
cocos2d::CCParticleSystem::stopSystem(*(_QWORD *)(a1 + 2216));
cocos2d::CCParticleSystem::stopSystem(*(_QWORD *)(a1 + 2224));
if ( a2 | *(_BYTE *)(a1 + 1972) ^ 1 || *(_BYTE *)(a1 + 1787) == 1 )
return (*(__int64 (__fastcall **)(__int64, _QWORD))(*(_QWORD *)a1 + 912LL))(a1, 0);
else
return PlayerObject::playDeathEffect(a1, 0, v12, *(double *)a3.i64, *(double *)a4.i64, a5, a6);
}