//
// sub_10045D458 from 0x10045d458 to 0x10045d4c4 (108 bytes)
//
// 1 xrefs:
// > sub_10045A37C @ 0x10045c708
//
// 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:27 +0000
//
__int64 __fastcall sub_10045D458(__int64 a1, __int64 a2)
{
int v3; // w0
int v4; // w8
int v5; // w8
int v6; // w8
if ( *(int *)(a1 + 1272) >= 1000 )
*(_DWORD *)(a1 + 1272) = 0;
v3 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a2 + 64LL))(a2);
v4 = *(_DWORD *)(a1 + 1272);
if ( v3 == 1 )
v5 = v4 - 1;
else
v5 = v4 + 1;
v6 = v5 & ~(v5 >> 31);
if ( v6 >= 999 )
v6 = 999;
*(_DWORD *)(a1 + 1272) = v6;
sub_10045DE84(a1);
return sub_10045D620(a1);
}