//
// GameLevelManager::storeDailyLevelState from 0x100580df0 to 0x100580f4b (347 bytes)
//
// 1 xrefs:
// > GameLevelManager::onGetGJDailyLevelStateCompleted @ 0x10052df1c
//
// 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 12:32:20 +0000
//
__int64 __fastcall GameLevelManager::storeDailyLevelState(_DWORD *a1, int a2, int a3, int a4)
{
__int64 result; // rax
timeb v6; // [rsp+8h] [rbp-28h] BYREF
switch ( a4 )
{
case 2:
ftime(&v6);
result = (unsigned int)(int)((double)a3 + (double)v6.millitm / 1000.0 + (double)SLODWORD(v6.time));
a1[220] = result;
a1[221] = a2;
if ( a1[225] < a2 )
a1[225] = a2;
if ( a1[231] < a2 )
a1[231] = a2;
break;
case 1:
ftime(&v6);
result = (unsigned int)(int)((double)a3 + (double)v6.millitm / 1000.0 + (double)SLODWORD(v6.time));
a1[217] = result;
a1[218] = a2;
if ( a1[224] < a2 )
a1[224] = a2;
if ( a1[230] < a2 )
a1[230] = a2;
break;
case 0:
ftime(&v6);
result = (unsigned int)(int)((double)a3 + (double)v6.millitm / 1000.0 + (double)SLODWORD(v6.time));
a1[214] = result;
a1[215] = a2;
if ( a1[223] < a2 )
a1[223] = a2;
if ( a1[229] < a2 )
a1[229] = a2;
break;
}
return result;
}