//
// cocos2d::CCDirector::popSceneWithTransition from 0xd49b90 to 0xd49c60 (208 bytes)
//
// 2 xrefs:
// > GameManager::safePopScene @ 0x717f7c
// > ??> @ 0xaadd0
//
// 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 13:07:37 +0000
//
__int64 __fastcall cocos2d::CCDirector::popSceneWithTransition(__int64 a1, int a2, float a3)
{
int v7; // w1
cocos2d::CCArray *v8; // x0
cocos2d::CCTransitionMoveInT *v9; // x0
cocos2d::CCScene *v10; // x1
__int64 v11; // x0
if ( *(_BYTE *)(a1 + 176) )
return 0;
cocos2d::CCDirector::checkSceneReference(a1);
cocos2d::CCArray::removeLastObject(*(cocos2d::CCArray **)(a1 + 296), 1u);
v7 = cocos2d::CCArray::count(*(cocos2d::CCArray **)(a1 + 296));
if ( v7 )
{
v8 = *(cocos2d::CCArray **)(a1 + 296);
*(_BYTE *)(a1 + 288) = 1;
v9 = (cocos2d::CCTransitionMoveInT *)cocos2d::CCArray::objectAtIndex(v8, v7 - 1);
*(_QWORD *)(a1 + 280) = v9;
if ( a2 == 1 )
v11 = cocos2d::CCTransitionMoveInT::create(v9, a3, v10);
else
v11 = cocos2d::CCTransitionFade::create(v9, a3, v10);
*(_QWORD *)(a1 + 280) = v11;
*(_BYTE *)(a1 + 176) = 1;
return 1;
}
else
{
cocos2d::CCDirector::end(a1);
return 1;
}
}