Complete.Org: Mailing Lists: Archives: freeciv-dev: February 2002:
[Freeciv-Dev] Re: [patch rfd] loading rulesets
Home

[Freeciv-Dev] Re: [patch rfd] loading rulesets

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: "Per I. Mathisen" <Per.Inge.Mathisen@xxxxxxxxxxx>, freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: [patch rfd] loading rulesets
From: Raahul Kumar <raahul_da_man@xxxxxxxxx>
Date: Fri, 22 Feb 2002 04:17:57 -0800 (PST)

--- "Per I. Mathisen" <Per.Inge.Mathisen@xxxxxxxxxxx> wrote:
> This patch is for getting access to ruleset info during pre-game, as
> discussed earlier in this thread.
> 
> It moves the loading of rulesets from start of game to before pre-game, ie
> to server initialization. I also removed the entirely unnecessary
> "feature" that allowed you to mix ruleset files from different modpacks in
> the same game. Now you just feed civserver with a modpack directory
> through the "--config DIR" option, and you cannot use "set techs FILE"
> anymore. Lastly, I killed data/classic/, since I really couldn't bother to
> code around this ancient backwards compatibility hack.
> 
> This also has three side benefits:
>  - rules out a class of possible inconsistencies stemming from mixing
> incompatible ruleset files (they are incompatible more often than not)
>  - ruleset errors are detected before you start the game, which means
> before you invite all your friends into the game...

>  - no more "set techs 3" server crashes

I did not pick that up in the patch. Which lines were these?
> 
> Also, it simplies the code a bit. Adds 69 lines and removes 809... :)
> 

Basically, you got rid of the default ruleset directory, and everything in
the code which loaded the default ruleset directory. You made one minor change
to the error messages

-  freelog(LOG_ERROR, _("Could not find readable file \"%s\" in data path."),
+  freelog(LOG_NORMAL, _("Could not find readable file \"%s\" in data path."),
            filename);

I don't see why you changed it from error to normal logging, but I trust you
have your reasons. The patch seems good, and it prompts me to say, "Why didn't
someone else beat you to it?". I also want to know if I can bribe you to go
to work for Mozilla/Gnome. Someone really needs to teach those guys the meaning
of lean mean code.

I trust that no major errors occured when you compiled it against current CVS.
Go for inclusion.


> Yours,
> Per
> 
> "What we anticipate seldom occurs: but what we least expect generally
> happens." -- Benjamin Disraeli



__________________________________________________
Do You Yahoo!?
Yahoo! Sports - Coverage of the 2002 Olympic Games
http://sports.yahoo.com


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