[Freeciv-Dev] Re: (PR#3489) Patch to add new generator
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
There were two versions, dif_00 contains the code to do a full
reread of the savegame which I never really got to work as the
game load is embedded and not really modular. But one could
presumably change it to longjmp back up to the start once it
had a savegame to read, if working through the details got too
cumbersome. Reading the full game in means you could use this
as a game selector as well as just a map generator.
The second dif_01 just reads in the new map generation stuff.
There are potential sanity checks that should be done here to
make sure the map read back corresponds to the right game. It
works fine using the standalone mapgenerator that was also in
the drop.
Enjoy,
RossW
=====
P.S. You seem to have read even less than I thought in spite of
weeks of promises :-(.
Gregory Berkolaiko wrote:
> On Sun, 6 Apr 2003, rwetmore@xxxxxxxxxxxx wrote:
>
>
>>Gregory Berkolaiko wrote:
>>
>>>Josh,
>>
>>[...]
>>
>>>Right now there are attempts to rewrite and clean up the map generation.
>>>It is planned to have a possibility of "external" or "pluggable" map
>>>generators, although I am not sure if there are any ideas concerning the
>>>implementation. I feel that your generator falls into this cathegory of
>>>external generators.
>>
>>There is a 40-line patch to mapgen that provides a completely generic
>>interface to add an arbitrary map generator. It basically calls an
>>external program to update the savegame file and reads the result
>>back in instead of calling the main generator entry point in mapgen.c
>>
>>Not much more is needed than that.
>>
>>You chose to ignore it in your promised look at the code last fall, so it
>>is no wonder you have forgotten :-)
>
>
> What code are we talking about here? It cannot be the map-everything
> rewrite, because that wasn't 40 lines, I remember clearly! ;)
>
> Can you resend the patch, please?
>
> G.
mapgen.zip
Description: mapgen.zip
|
|