//
// GameLevelManager::getSavedLevel from 0x7ffe94 to 0x7ffee4 (80 bytes)
//
// 10 xrefs:
// > LevelInfoLayer::onDeathTracker @ 0x7e5294
// > EditLevelLayer::onDeathTracker @ 0x7ed404
// > GameLevelManager::saveFetchedLevels @ 0x8056ec
// > GameLevelManager::saveLevel @ 0x819b3c
// > GameLevelManager::gotoLevelPage @ 0x81a4e8
// > GameLevelManager::processOnDownloadLevelCompleted @ 0x859834
// > InfoLayer::onLevelInfo @ 0x90a49c
// > DailyLevelPage::refreshDailyPage @ 0xa6f1b0
// > GauntletLayer::unlockActiveItem @ 0xa783b8
// > ??> @ 0x9fbe0
//
// 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 12:54:43 +0000
//
__int64 __fastcall GameLevelManager::getSavedLevel(GameLevelManager *this, GJGameLevel *a2)
{
int v2; // w2
if ( !a2 )
return 0;
v2 = *((_DWORD *)a2 + 230) - *((_DWORD *)a2 + 231);
if ( v2 > 0 )
return GameLevelManager::getSavedDailyLevel(this, (const char *)(unsigned int)v2);
if ( *((_BYTE *)a2 + 649) )
return GameLevelManager::getSavedGauntletLevel(
this,
(const char *)(unsigned int)(*((_DWORD *)a2 + 82) - *((_DWORD *)a2 + 83)));
return GameLevelManager::getSavedLevel(
this,
(const char *)(unsigned int)(*((_DWORD *)a2 + 82) - *((_DWORD *)a2 + 83)));
}