melonDS-emu / melonDS

DS emulator, sorta
https://melonds.kuribo64.net
GNU General Public License v3.0
3.18k stars 527 forks source link

[Regression] RTC does not handle 24h mode anymore #1945

Open Real96 opened 8 months ago

Real96 commented 8 months ago

Seems like melonDS atm does not have the 24h mode for rtc, only the 12h one. Maybe it should be good to leave the choice to the user with an setting option(?).

This is the issue i'm facing: gen5 pokemon games don't generate correct initial seeds if the time is set after 12:00 pm. The initial seed is rtc dependant.

The recent rtc commits seem to have caused it. It was working fine before that commit.

CasualPokePlayer commented 8 months ago

This isn't a regression per se, it was only ever ""correct"" on BizHawk once due to its changes, since it took all the changes from upstream (since they make the BizHawk changes obsolete) it "regressed" for BizHawk specifically.

To be clear, what the actual issue here is strange. By default, melonDS is in 12 hour mode. Pokemon games seem to expect 24 hour mode (note that previously, with ""correct"" code, 24 hour mode was always assumed). Reportedly, even booting into firmware and changing the time in firmware did not result in the "correct" seeds, indicating that either the firmware and/or Pokemon does not bother switching to 24 hour mode, or they do but that switch isn't happening correctly for some reason, or the AM/PM flag is simply not being reported correctly in 24 hour mode even when it should be.

The last doesn't seem likely looking at the code, so I could guess it's either the first or second possibilities.

Arisotura commented 8 months ago

we've been talking about this and apparently the DS just uses 24-hour mode always from what it seems, so we might as well just make that the default

BlueSwordM commented 2 months ago

Has there been any progress on the issue or has it been fixed on Git already?