Summary: Allow custom types for governments to be used in
effect requirements.
                 Project: Freeciv
            Submitted by: henkutsu_tama
            Submitted on: Sat 16 Jun 2012 10:36:38 PM GMT
                Category: general
                Priority: 5 - Normal
                  Status: None
                 Privacy: Public
             Assigned to: None
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: 



I am fairly sure this would be a big project (I am not a programmer), needing
changes to;
packets.def ?
(perhaps adding govtypes.c/h as well?)

But it looks like most of the code can be copied from the infrastructure
needed for unit types, and there are good reasons for doing it:

After reading through all the rulesets I can get my hands on, (aliens,
ancients, Civ2-3, etc) and writing my own I have notice that there is a huge
amount of repetition when tying effects to governments, and that repetition
increases the chances of errors/difficulty of modifying and lowers

Some time ago it was proposed on the wiki to radically change how governments
work; ethos, scope etc. Not all of these fit together well so there would have
to be relation rules.. and it becomes a mess. HOWEVER! Setting anarchy to 1
turn and (using my ruleset as an example) having 15 different governments
across a [3 (size),3 (focus),2 (antiquity)] matrix with their own quirks works
just as well, and seems to be understandable by the ai without any changes.
(need to do more testing). The only problem is defining everything, and the
amount of req{} nreq{} gets ridiculous. 

Being able to just write
; Voting governments have a senate that may prevent war
type  = "Has Senate"
value   = 1
reqs    =
    { "type",       "name",      "range"
      "GovType", "Voting",  "Player"

; Economically geared societies gain a trade bonus
type    = "Output_Inc_Tile"
value   = 1
reqs    =
    { "type",       "name",      "range"
      "GovType", "FocusEconomy", "Player"
      "OutputType", "Trade", "Local"

; Unsophisticated governance leads to lazy loafers
type    = "Output_Penalty_Tile"
value   = 2
reqs    =
    { "type",       "name",      "range"
      "GovType", "Primitive",  "Player"

; Temple effects reduced under 'rational' governments, unless it is a cult of
type    = "Make_Content"
value   = -1 
reqs    =
    { "type",       "name",      "range"
      "GovType", "Rational",  "Player"
    { "type",       "name",      "range"
      "GovType", "CultLeader",  "Player"
These are simple but common instances where flags would help. In more complex
situations, such as where a wonder improves the effect of a building, but only
under/in a different way under different governments.

Again, I am not a programmer. I can't svn or diff to save my life but I will
have a go at implementing this on a daily snapshot. If I can get it to work
(not likely, but I'll try), I'll upload the modified files and let someone
smarter diff them.


Reply to this item at:


  Message sent via/by Gna!

Freeciv-dev mailing list

Reply via email to