A bit more goes into a savestate than just a copy of RAM like Wikipedia says. You'd also store the emulated CPU state(registers, program counter/instruction pointer, etc.) and the input state; basically the status of the entire console itself. Everything the emulator does is stored somewhere in memory, so it's just a matter of writing it out to a file, and then loading from it at a later point once the user directs the program to do so. Of course, that doesn't include extra things like different versions of save states/emulators, etc.. For that you'd likely write a header to the save state followed by the raw state data.
4GHz AMD 3900X, 32GB DDR4 RAM, 6GB Nvidia RTX 2060, Asus Crosshair 7 Hero (Wifi), Linux
How to ask useful questions: https://web.archive.org/web/20110214010944/http://support.microsoft.com/kb/555375
I'm not Dark_Alex, nor do I claim to be. Our nicknames are merely coincidence.
How to ask useful questions: https://web.archive.org/web/20110214010944/http://support.microsoft.com/kb/555375
I'm not Dark_Alex, nor do I claim to be. Our nicknames are merely coincidence.

