ekeeke / Genesis-Plus-GX

An enhanced port of Genesis Plus - accurate & portable Sega 8/16 bit emulator
Other
676 stars 194 forks source link

Broken save state compatibility again #194

Closed clobber closed 6 years ago

clobber commented 6 years ago

Commit https://github.com/ekeeke/Genesis-Plus-GX/commit/9bb64c47f969dffe44c4bafe1f2651b88652ab36 broke compatibility with previous Genesis/Mega Drive save states. Is it possible to fix this?

ekeeke commented 6 years ago

Nope, this is inherent to core changes

ghost commented 6 years ago

@clobber I don't think it's reasonable to expect states to work between versions where significant changes may have occurred. If you're using states for archival purposes, I would recommend keeping a copy of the core you used at the time. For regular gameplay, I wouldn't update until you're done with that playthrough, or have an SRM to load.

KMFDManic commented 6 years ago

@ekeeke does a hell of a lot for the emulation scene. I appreciate it all. But, with change comes compromise, unfortunately.

rz5 commented 6 years ago

@ekeeke, hi.

Some concerns have been raised about these types of core changes breaking old save states and examples of how to address this problem include mupen64-plus and Mednafen, projects which both have some sections of kludge code for the sake of the end-user.

Bumping the version number in the line that @clobber linked won't make old save states work but it would at least make the core not crash...could you please give this problem some of your time?

ekeeke commented 6 years ago

@clobber: I don't owe you anything, getting angry or calling people out over such tiny issue won't get you anywhere either. Again, broken savestate is something that cannot be fixed when I completely rewrite something from scratch (PSG core) and drop the older core or when new stuff are added. Maintaining backward compatibility is something I tried for a while but it became too much complicated and time consuming. I myself do not have much free time anymore to fully maintain this emulator so be happy I still commit some stuff from time to time. If someone has time for this and has a solution to propose, fell free to submit pull requests, that's what github is for.

I agree that I should at least have bumped the state version to prevent unexpected crash but I guess I was waiting for the official 1.7.5 release (which never happened, again because of lack of time). I will try to at least take this in consideration for future builds (for now it's too late as bumping the state version without any state changes would break compatibility with states made since the last state change).

For the record, here are (in chronological order) the commits which modified the state format without bumping the state version (1.7.5) :

https://github.com/ekeeke/Genesis-Plus-GX/commit/ec554b4b702d337168dfcaf4b4a6248062e2db5b (addition of h_counter variable in VDP context ) https://github.com/ekeeke/Genesis-Plus-GX/commit/8392d93fcb5c1df63db7b232bc701559486a5c25 (addition of scd.stopwatch in SCD context) https://github.com/ekeeke/Genesis-Plus-GX/commit/9bb64c47f969dffe44c4bafe1f2651b88652ab36 (rewrite of PSG core) https://github.com/ekeeke/Genesis-Plus-GX/commit/757a6e0c1f4f116b8d5e2a1b755cc5eaba4d3b3c (addition of nuked YM3438 core in libretro core)

If you have 1.7.5 savestate files which crash the latest builds, you could just go back in time and compile builds before each of theses commits then try to use them to load your state (and either finish your game or use in-game SRAM feature to switch to latest builds)

clobber commented 6 years ago

@ekeeke Okay, understood. Sorry to come off as rude and entitled.