Complete.Org: Mailing Lists: Archives: freeciv-dev: May 2002:
[Freeciv-Dev] Re: Message options not evaluated (PR#1499)
Home

[Freeciv-Dev] Re: Message options not evaluated (PR#1499)

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Raimar Falke <rf13@xxxxxxxxxxxxxxxxx>
Cc: Christian Knoke <chrisk@xxxxxxxx>, freeciv-dev@xxxxxxxxxxx, bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: Message options not evaluated (PR#1499)
From: Mike Kaufman <kaufman@xxxxxxxxxxxxxxxxxxxxxx>
Date: Sun, 26 May 2002 12:51:43 -0500

On Sun, May 26, 2002 at 01:50:26PM +0200, Raimar Falke wrote:
> On Fri, May 24, 2002 at 02:10:34PM -0700, Christian Knoke wrote:
> > CVS 23 MAY 2002
> > 
> > After starting a saved game, in the first round, I get
> > a message in the message window: 
> > 
> > "Basra may soon grow to size 3",
> > 
> > even if in message options, City: May soon grow,
> > the second check box if off.
> 
> This is because load_options is called too late.
> 
> Since I don't see a reason why load_options should be called multiple
> time I moved it to the client startup.

here's the problem, and I'm not sure how to fix it properly. load_options() 
must be called _after_ the rulesets are sent to the client so that global
worklists are loaded properly, otherwise you get blank worklists (cause
game.num_impr_types = 0 or some such.)

-mike

> 
>       Raimar
> 
> -- 
>  email: rf13@xxxxxxxxxxxxxxxxx
>   Living on earth may be expensive, but it includes an annual free trip
>   around the sun.

> ? 1498_fix1.diff
> ? autogame
> ? civscore.log
> ? diff
> ? graphs
> ? input_checking1.diff
> ? input_checking_invis1.diff
> ? invis1.diff
> ? common/_o2
> ? common/a
> ? common/size
> ? common/size2
> Index: client/civclient.c
> ===================================================================
> RCS file: /home/freeciv/CVS/freeciv/client/civclient.c,v
> retrieving revision 1.131
> diff -u -r1.131 civclient.c
> --- client/civclient.c        2002/05/26 09:55:41     1.131
> +++ client/civclient.c        2002/05/26 11:43:52
> @@ -194,6 +194,7 @@
>    game_init();
>    attribute_init();
>    agents_init();
> +  load_options();
>  
>    /* This seed is not saved anywhere; randoms in the client should
>       have cosmetic effects only (eg city name suggestions).  --dwp */
> @@ -559,7 +560,6 @@
>      client_state=newstate;
>  
>      if(client_state==CLIENT_GAME_RUNNING_STATE) {
> -      load_options();
>        create_event(-1, -1, E_GAME_START, _("Game started."));
>        update_research(game.player_ptr);
>        role_unit_precalcs();



[Prev in Thread] Current Thread [Next in Thread]