//
// SecretRewardsLayer::onBack from 0xb9a7ec to 0xb9a854 (104 bytes)
//
// 4 xrefs:
// > SecretRewardsLayer::keyBackClicked @ 0xb9a858
// > ??> @ 0xd4a58
// > SecretRewardsLayer::init @ 0xb9f3f8
// > ??> @ 0x1546538
//
// 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:02:43 +0000
//
__int64 __fastcall SecretRewardsLayer::onBack(SecretRewardsLayer *this, cocos2d::CCObject *a2)
{
GameManager *v3; // x0
cocos2d::CCDirector *v4; // x0
CreatorLayer *v5; // x19
AppDelegate *v6; // x0
cocos2d::CCScene *v7; // x1
cocos2d::CCScene *v8; // x0
if ( !*((_BYTE *)this + 584) )
return SecretRewardsLayer::moveToMainLayer(this, a2);
v3 = (GameManager *)GameManager::sharedState(this);
GameManager::fadeInMenuMusic(v3);
v4 = (cocos2d::CCDirector *)(*(__int64 (__fastcall **)(SecretRewardsLayer *, _QWORD))(*(_QWORD *)this + 1072LL))(
this,
0);
v5 = (CreatorLayer *)cocos2d::CCDirector::sharedDirector(v4);
v6 = CreatorLayer::scene(v5);
v8 = (cocos2d::CCScene *)cocos2d::CCTransitionFade::create(v6, 0.5, v7);
return cocos2d::CCDirector::replaceScene(v5, v8);
}