// skip BIOS logos and region check
psxCpu->Notify(R3000ACPU_NOTIFY_BEFORE_SAVE, NULL);
psxRegs.pc = psxRegs.GPR.n.ra;
// skip BIOS logos and region check
psxCpu->Notify(R3000ACPU_NOTIFY_BEFORE_SAVE, NULL);
psxRegs.pc = psxRegs.GPR.n.ra;
memcpy(head, buf + 12, sizeof(EXE_HEADER));
size = SWAP32(head->t_size);
memcpy(head, buf + 12, sizeof(EXE_HEADER));
size = SWAP32(head->t_size);
misc->magic = MISC_MAGIC;
misc->gteBusyCycle = psxRegs.gteBusyCycle;
misc->muldivBusyCycle = psxRegs.muldivBusyCycle;
misc->magic = MISC_MAGIC;
misc->gteBusyCycle = psxRegs.gteBusyCycle;
misc->muldivBusyCycle = psxRegs.muldivBusyCycle;
psxCpu->Notify(R3000ACPU_NOTIFY_BEFORE_SAVE, NULL);
SaveFuncs.write(f, (void *)PcsxHeader, 32);
psxCpu->Notify(R3000ACPU_NOTIFY_BEFORE_SAVE, NULL);
SaveFuncs.write(f, (void *)PcsxHeader, 32);