Hi @ all...
I have a game working under Win32 which cannot save the current game. I would like to make it able this way: I think that saving the DATA memory area only (not the CODE memory area) to a file and restoring it should work (DATA section is not read only as the CODE section, isn't it?). Is this correct?
If it's correct, where can I look to see which is the BASE address and how LONG the DATA section extends? How can I see if there are more than 1 DATA section?

Thanx in advance.

Sincerely,
Daniel
Posted on 2001-10-22 15:18:40 by dguzz
I don't like this idea very much :). First of all, there could be windows
states you aren't able to save (GDI, DX, OGL, or whatever). Second,
you cannot save dynamically allocated memory structures this way.

Third, it's the sloppy and "easy way out" way of doing it :).

The "good way" to do it would be to realizing what stuff you *need*
to save the gamestate, and group that together, and only write
that to your file. This requires some thinking and planning though :).
Posted on 2001-10-22 17:02:12 by f0dder
Probably I didn'e explained well.
The game I'm writing about is not mine (I do not have a source code). It is a freeware backgammon which cannot save the current game (ok... backgammon match are not so long but...).
So I wanted to save its state by myself (something like the MAME - Multiple Arcade Machine Emulator - does when saving the rom state).

In any case, thanx f0dder.

Sincerely,
Daniel
Posted on 2001-10-23 12:25:45 by dguzz