//
// UILayer::onPause from 0x100050b34 to 0x100050b80 (76 bytes)
//
// 4 xrefs:
// > UILayer::handleAction @ 0x100052160
// > UILayer::keyBackClicked @ 0x1000526a8
// > sub_1000526B8 @ 0x1000526e8
// > UILayer::init @ 0x100050720
//
// 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 10:57:43 +0000
//
__int64 __fastcall UILayer::onPause(__int64 a1)
{
__int64 v2; // x0
__int64 result; // x0
v2 = GameManager::sharedState(a1);
if ( !*(_QWORD *)(v2 + 544) )
return UILayer::doPause(a1);
result = GameManager::sharedState(v2);
if ( *(int *)(*(_QWORD *)(result + 544) + 1924LL) <= 2 )
return UILayer::doPause(a1);
return result;
}