Complete.Org: Mailing Lists: Archives: freeciv-dev: June 1999:
Re: [Freeciv-Dev] [2 x Patch] struct government + unit upkeep
Home

Re: [Freeciv-Dev] [2 x Patch] struct government + unit upkeep

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: freeciv-dev@xxxxxxxxxxx
Subject: Re: [Freeciv-Dev] [2 x Patch] struct government + unit upkeep
From: "Bobby D. Bryant" <bdbryant@xxxxxxxxxxxxxxx>
Date: Thu, 03 Jun 1999 22:04:43 -0500

David Pfitzner wrote:

> Sune Kirkeby wrote:
> >
> > Firstly is the "struct government" patch, which joins all the
> > information about a government in one struct, and creates an
> > array of these (hardcoded).
>
> Sounds good.  Should be an easy step to fill this struct array
> from a "governments" ruleset file.  Someone posted before the
> ruler titles used by Civ2; check the archives.

Keep in mind that the governments might be given different names in a
modpack, so try to work with the names of government-type technologies
actually loaded, rather than with the hard-coded constants.  For
example, recent versions of my "ancients" modpack have used a
government/tech called "The Principate".  To maintain the modpack, I
would want to edit the (suggested) governments.ruleset, and define flags
for "The Principate" rather than the name of whatever hard-coded
government type I was replacing.  This will take a bit more coding, but
will make life much easier for .ruleset maintainers over the long haul.

Also, I've been wanting to suggest that we allow a variable number of
government definitions -- I could have used a couple more in my
modpack.  You might not want to add that capability without more
discussion here, but please keep it in mind when you write your code, so
it will be easy to change later if the suggestion is adopted.

Since goverments=techs in the current implementation, one of two
suggestions might be profitable:

a) add a flag to techs.ruleset, indicating that the flagged tech is a
government type, or

b) divorce the governments=techs association, leave techs.ruleset
unchanged, and let governments.ruleset specify a technology that is
required before you can select that government type (i.e., treat
governments as something you can "do" with a technology, just like
buildings and units).

Suggestion (b) needs discussion, as it diverges from the CivI/II
pattern, but might be more flexible in the long run.  I would, however,
be quite happy with (a) if it allowed a variable number of governments
to be defined, and if governments.ruleset provided flags to allow
control of *all* the effects of a government.

OTOH, if (a) is selected it might be best to put the government info at
the bottom of techs.ruleset, since governments *are* techs under this
interpretation, and all the tech info might as well go in techs.ruleset.

Bobby Bryant
Austin, Texas



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