//
// GJBaseGameLayer::processCameraObject from 0x8599fc to 0x859ac0 (196 bytes)
//
// 5 xrefs:
// > GJBaseGameLayer::switchToFlyMode @ 0x859c44
// > GJBaseGameLayer::switchToRobotMode @ 0x859d88
// > GJBaseGameLayer::switchToSpiderMode @ 0x859df4
// > GJBaseGameLayer::switchToRollMode @ 0x859e60
// > ??> @ 0x3d1a0
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
GameObject *GJBaseGameLayer::processCameraObject(GJBaseGameLayer *a1, GameObject *a2, PlayerObject *a3)
{
GameObject *m_lastActivatedPortal2; // x19
const cocos2d::CCPoint *v6; // x0
float v7; // s0
float v8; // s1
_BOOL4 m_isDualMode; // w0
cocos2d::CCPoint v11; // [xsp+40h] [xbp+40h] BYREF
m_lastActivatedPortal2 = a2;
if ( a2 )
{
v6 = a2->getPosition(a2);
cocos2d::CCPoint::CCPoint(&v11, v6);
cocos2d::CCPoint::operator=(&a3->m_lastPortalPos, v7, v8);
m_isDualMode = a1->m_gameState.m_isDualMode;
a3->m_lastActivatedPortal = m_lastActivatedPortal2;
if ( m_isDualMode && a1->m_gameState.m_lastActivatedPortal2 )
m_lastActivatedPortal2 = a1->m_gameState.m_lastActivatedPortal2;
goto LABEL_3;
}
if ( a1->m_gameState.m_isDualMode )
{
m_lastActivatedPortal2 = a1->m_gameState.m_lastActivatedPortal2;
if ( m_lastActivatedPortal2 )
LABEL_3:
a1->m_gameState.m_lastActivatedPortal1 = m_lastActivatedPortal2;
}
return m_lastActivatedPortal2;
}