//
// GJBaseGameLayer::spawnPlayer2 from 0x99e838 to 0x99e8bc (132 bytes)
//
// 2 xrefs:
// > GJBaseGameLayer::toggleDualMode @ 0x9e6d4c
// > ??> @ 0x8e0a8
//
// 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 12:58:06 +0000
//
__int64 __fastcall GJBaseGameLayer::spawnPlayer2(GJBaseGameLayer *this)
{
__int64 v3; // x0
if ( !(*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 408) + 512LL))(*((_QWORD *)this + 408)) )
{
v3 = (*(__int64 (__fastcall **)(_QWORD))(**((_QWORD **)this + 407) + 512LL))(*((_QWORD *)this + 407));
(*(void (__fastcall **)(__int64, _QWORD, __int64))(*(_QWORD *)v3 + 464LL))(v3, *((_QWORD *)this + 408), 59);
if ( !*((_BYTE *)this + 12236) )
PlayerObject::addAllParticles(*((PlayerObject **)this + 408));
}
return PlayerObject::spawnFromPlayer(
*((PlayerObject **)this + 408),
*((PlayerObject **)this + 407),
*((_BYTE *)this + 1912) ^ 1u);
}