X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=libpcsxcore%2Fmisc.c;h=d52a931c805501f4593e0128aa23f49e32c841a7;hb=980f7a58b47fefd3424bf8d55f6345128dc3774c;hp=8010d7a5baf9f8452f6aa76b617fa84b6a2b3c8d;hpb=4d66d894c6563cbfb78fe8ccc0b374809fc44b0d;p=pcsx_rearmed.git diff --git a/libpcsxcore/misc.c b/libpcsxcore/misc.c index 8010d7a5..d52a931c 100644 --- a/libpcsxcore/misc.c +++ b/libpcsxcore/misc.c @@ -608,7 +608,7 @@ int SaveState(const char *file) { f = SaveFuncs.open(file, "wb"); if (f == NULL) return -1; - new_dyna_before_save(); + psxCpu->Notify(R3000ACPU_NOTIFY_BEFORE_SAVE, NULL); SaveFuncs.write(f, (void *)PcsxHeader, 32); SaveFuncs.write(f, (void *)&SaveVersion, sizeof(u32)); @@ -655,8 +655,6 @@ int SaveState(const char *file) { SaveFuncs.close(f); - new_dyna_after_save(); - return 0; } @@ -685,15 +683,15 @@ int LoadState(const char *file) { if (Config.HLE) psxBiosInit(); - psxCpu->Reset(); SaveFuncs.seek(f, 128 * 96 * 3, SEEK_CUR); - SaveFuncs.read(f, psxM, 0x00200000); SaveFuncs.read(f, psxR, 0x00080000); SaveFuncs.read(f, psxH, 0x00010000); SaveFuncs.read(f, &psxRegs, offsetof(psxRegisters, gteBusyCycle)); psxRegs.gteBusyCycle = psxRegs.cycle; + psxCpu->Notify(R3000ACPU_NOTIFY_AFTER_LOAD, NULL); + if (Config.HLE) psxBiosFreeze(0); @@ -795,6 +793,7 @@ int RecvPcsxInfo() { SysClose(); return -1; } psxCpu->Reset(); + psxCpu->Notify(R3000ACPU_NOTIFY_AFTER_LOAD, NULL); } return 0;