//
// SecretRewardsLayer::onBack from 0x100384b34 to 0x100384ba0 (108 bytes)
//
// 3 xrefs:
// > SecretRewardsLayer::keyBackClicked @ 0x100389c74
// > sub_100389C78 @ 0x100389c80
// > SecretRewardsLayer::init @ 0x1003834f0
//
// 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 11:03:32 +0000
//
__int64 __fastcall SecretRewardsLayer::onBack(_BYTE *a1)
{
__int64 v2; // x0
__int64 v3; // x19
_QWORD *v4; // x0
char *v5; // x1
if ( (a1[584] & 1) == 0 )
return sub_1003859CC(a1);
v2 = GameManager::sharedState(a1);
GameManager::fadeInMenuMusic(v2);
(*(void (__fastcall **)(_BYTE *, _QWORD))(*(_QWORD *)a1 + 1072LL))(a1, 0);
v3 = cocos2d::CCDirector::sharedDirector();
v4 = CreatorLayer::scene();
v5 = cocos2d::CCTransitionFade::create_1((__int64)v4, 0.5);
return cocos2d::CCDirector::replaceScene(v3, v5);
}