- Messages
- 12
- Country

Hello,
I'm learning how to connect FS2004 to my C app using FSUIPC.
I obtained the MSFS Time but I coudn't get the Year, Month, Day and other vars... What am I doing wrong?
I Found the code above at FSUIPC SDK so I tried to do the same using the Year offset (0x240)
The console printed
FS clock = 07:25:22
Year = -40 7
Can someone help me?
thanks in advance.
I'm learning how to connect FS2004 to my C app using FSUIPC.
I obtained the MSFS Time but I coudn't get the Year, Month, Day and other vars... What am I doing wrong?
Code:
if (!FSUIPC_Read(0x238, 4, chTime, &dwResult) || !FSUIPC_Process(&dwResult)) {
fTimeOk = FALSE;
}
...
...
...
if(fTimeOk) {
printf("FS clock = %02d:%02d:%02d\n", chTime[0], chTime[1], chTime[2]);
}
I Found the code above at FSUIPC SDK so I tried to do the same using the Year offset (0x240)
Code:
if(!FSUIPC_Read(0x0240, 2, year, &dwResult) || !FSUIPC_Process(&dwResult)) {
fYearOk = FALSE;
}
...
...
if(fYearOk) {
printf("Year = %d %d\n", year[0], year[1]);
}
The console printed
FS clock = 07:25:22
Year = -40 7
Can someone help me?
thanks in advance.
