Use overclock on load state

- Recalculate CPU counters using current clock speed on loading a new state
This commit is contained in:
iCatButler 2016-07-30 17:26:32 +01:00
parent 97105b26f2
commit d5b40fbbe0
1 changed files with 4 additions and 0 deletions

View File

@ -521,6 +521,10 @@ s32 psxRcntFreeze( gzFile f, s32 Mode )
if (Mode == 0) {
psxHsyncCalculate();
// iCB: recalculate target count in case overclock is changed
rcnts[3].target = (PSXCLK / (FrameRate[Config.PsxType] * HSyncTotal[Config.PsxType]));
if(rcnts[1].rate != 1)
rcnts[1].rate = (PSXCLK / (FrameRate[Config.PsxType] * HSyncTotal[Config.PsxType]));
}
return 0;