//
// SongOptionsLayer::onSongPersistent from 0x140166150 to 0x140166189 (57 bytes)
//
// 2 xrefs:
// > SongOptionsLayer::init @ 0x140165b7e
// > ??> @ 0x140917f24
//
// This function is hookable on this platform (idp: pc, 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:27:27 +0000
//
__int64 __fastcall SongOptionsLayer::onSongPersistent(__int64 a1)
{
__int64 v1; // rbx
__int64 v2; // rax
__int64 v3; // rcx
__int64 result; // rax
v1 = a1;
v2 = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 664) + 24LL))(*(_QWORD *)(a1 + 664));
v3 = *(_QWORD *)(v1 + 664);
LOBYTE(v1) = *(_BYTE *)(v2 + 350) == 0;
result = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v3 + 24LL))(v3);
*(_BYTE *)(result + 350) = v1;
return result;
}