//
// LevelBrowserLayer::onExportSelected from 0x1004971a4 to 0x100497250 (172 bytes)
//
// 1 xrefs:
// > LevelBrowserLayer::init @ 0x100495acc
//
// 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:05:56 +0000
//
__int64 __fastcall LevelBrowserLayer::onExportSelected(__int64 result)
{
__int64 v1; // x19
_QWORD *v2; // x20
__int64 v3; // x8
unsigned int *v4; // x9
__int64 v5; // x8
unsigned __int64 v6; // x21
unsigned __int64 v7; // x22
__int64 v8; // x0
__int64 v9; // x1
if ( *(_QWORD *)(result + 656) )
{
v1 = result;
v2 = sub_1002E736C();
v3 = *(_QWORD *)(v1 + 656);
if ( v3 )
{
v4 = *(unsigned int **)(v3 + 56);
v5 = *v4;
if ( (_DWORD)v5 )
{
v6 = *((_QWORD *)v4 + 2);
v7 = v6 + 8 * v5 - 8;
do
{
if ( !*(_QWORD *)v6 )
break;
if ( *(_BYTE *)(*(_QWORD *)v6 + 771LL) == 1 )
sub_1002E74E0((__int64)v2);
v6 += 8LL;
}
while ( v6 <= v7 );
}
}
result = sub_1002E757C((__int64)v2);
if ( (_DWORD)result )
{
v8 = LocalLevelManager::sharedState();
v9 = LocalLevelManager::exportLevelsToFile(v8, (__int64)v2);
return LevelBrowserLayer::showExportResult(v1, v9);
}
}
return result;
}