Modifing Game Options GUI

Can you help improve your favourite game? Hardcore C mages, talented artists, and players with any level of experience are welcome!
Post Reply
robfinch
Posts: 8
Joined: Sat Jan 23, 2016 10:38 pm

Modifing Game Options GUI

Post by robfinch »

I'd like to know what to do to modify the map generator selector under the game options.
I added another item to the generator enumerator.
Then I added another map generator to settings.c generator_name()
But the generator selection doesn't show up in the GUI.

I'm working on a fracture (not fractal) map generator. I added code for the map generator, and have it called from mapgen.c
Screenshot of a minimap from another program using the generator.
Map2a.gif
Map2a.gif (5.1 KiB) Viewed 5848 times
Is there a way to reveal the entire map for debugging ?
cazfi
Elite
Posts: 3095
Joined: Tue Jan 29, 2013 6:54 pm

Re: Modifing Game Options GUI

Post by cazfi »

robfinch wrote:But the generator selection doesn't show up in the GUI.
First make sure that it works on server side. The way server settings are transferred and handled in client GUI is not ideal. You're probably missing "enum to text" conversion or something else from server/settings.c.
robfinch wrote:Is there a way to reveal the entire map for debugging ?
When I'm checking results of a map generator and am not intereted about anything else, I usually simply "/endgame" for entire map to get revealed. There's also an option to reveal the map from the beginning, or you can make yourself global observer to see everything.
robfinch
Posts: 8
Joined: Sat Jan 23, 2016 10:38 pm

Re: Modifing Game Options GUI

Post by robfinch »

I figured it out. I wasn't re-running the install. 'make install'.
It was confusing because make generated a new .exe.
Either it worked or the map generator failed in a way that generated a map.
Next thing to do is refine it somewhat for continents/islands/Pangea.

I added a line or two of text in settings.c and now all the references to line numbers in the translation files are off.

Now to figure out how to change the resolution to full screen.
cazfi
Elite
Posts: 3095
Joined: Tue Jan 29, 2013 6:54 pm

Re: Modifing Game Options GUI

Post by cazfi »

btw. As you seem to have code-related questions regularly, you may want to ask them from freeciv-dev mailing list instead.

http://gna.org/mail/?group=freeciv
Post Reply