[Freeciv-Dev] Re: researchspeed patch
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
David, all --
--- David Pfitzner <dwpfitzner@xxxxxxxxx> wrote:
> Yeah. I'd be inclined to change the name, if we can find a shorter
> alternative :-)
Of course, I never type "set researchspeed" anyway, just "set res" How
about researchfactor (still ambiguous, but gets the idea across that
higher values are less advantageous).
> (If it is changed, is it worth supporting backward
> compatability to the old name, for scripts, and for people used to
> the current name?)
I'd guess it would be easy enough...
> > The only tricky bit is ensuring that save files with techlevel can
> > loaded in. I put a check on game.version to selectively load in
> > game.researchspeed or game.techlevel. I haven't really tested that,
> > however.
> This isn't a good way to do it. Some old code does this, but it
> is deprecated -- see comments up just a bit in game_load(). Instead,
> call section_file_lookup() to see if game.researchspeed is in the
> and if not then fall back to looking up game.techlevel.
The problem is that, after changing "techlevel" to "researchspeed" (or
whatever), I might then want to change game.tech to game.techlevel
(although game.tech is understandable on the analogy of game.gold...),
and then I'm in trouble. Checking on version is more generalizable, I
would think, and documents what happend better (prior to version x.y.z,
game.researchspeed was game.techlevel).
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail.