//
// sub_D7998 from 0xd7998 to 0xd79d4 (60 bytes)
//
// 2 xrefs:
// > sub_E98EC @ 0xe9f08
// > sub_EA0E4 @ 0xea12c
//
// 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:14:53 +0000
//
__int64 __fastcall sub_D7998(__int64 a1)
{
__int64 v1; // x8
int v2; // w9
int v3; // w14
int v4; // w9
__int64 v5; // x8
v1 = *(int *)(a1 + 32);
v2 = *(_DWORD *)(a1 + 8);
v3 = v2 + v1;
v4 = *(_DWORD *)(a1 + 40) + v2;
v5 = *(_QWORD *)a1 + *(int *)(a1 + 24) * v1;
*(_DWORD *)(a1 + 32) = v3 % *(_DWORD *)(a1 + 16);
*(_DWORD *)(a1 + 40) = v4;
return v5;
}