Complete.Org: Mailing Lists: Archives: freeciv-dev: July 2002:
[Freeciv-Dev] Re: RFC: Artillery Patch
Home

[Freeciv-Dev] Re: RFC: Artillery Patch

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: freeciv development list <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: RFC: Artillery Patch
From: Ben Webb <ben@xxxxxxxxxxxxxxxxxxxxxx>
Date: Mon, 8 Jul 2002 14:44:12 +0100

On Tue, Jul 02, 2002 at 06:26:00PM +0100, Ben Webb wrote:
> On Mon, Jul 01, 2002 at 11:42:48PM +0200, Per I Mathisen wrote:
> > BTW I just noticed Ben had a unit classes patch already done at
> > freecivac.sf.net.
> 
>       The patch as it is right now doesn't actually "work" as such; in
> fact, it just breaks a lot of existing impr-gen code. ;) If I'd been
> around last week I would have mentioned it, since it seems to do pretty
> much what Per has been suggesting. It will become a "gen. unit." patch
> in the not-too-distant future, I promise. Just ask me after next
> weekend. ;)

        As promised... effect-unit-v2.patch and impr-gen-20020708.patch are
now available at http://freecivac.sourceforge.net/. The former is a
patch that adds impr-gen effects for units, to apply after applying all
other impr-gen patches, while the latter includes all current impr-gen
patches, and should apply against today's CVS.

effect-unit-v2.patch does three distinct things:-
1. Unit classes are generalised. I got rid of all the old dodgy unit
   class code; unit classes now include unit movetype, unit flags, and
   any additional ruleset-defined classes. Unittypes can be members of
   multiple classes, although any given impr-gen effect can only be
   active against a single class.
2. impr-gen effects can now be given in units.ruleset, although they're not
   yet as flexible as those in buildings.ruleset. For example, you cannot
   specify a range for these effects; all such effects affect the given
   unit only, so you can't yet create a unit that influences every other
   unit on the map, for example. Also, it makes little sense to apply
   many of the impr-gen effects to a unit (e.g. Science_Bonus is
   meaningless, because units do not produce science). Two effects that
   do work, however, are Unit_Defend and Unit_Veteran. I've used these
   to replace the existing Pikemen/Horse/AEGIS flags, to fiddle with the
   defence strength of helicopters when attacked by planes, and to generalise
   the existing "veteran Diplomats" code. No need for random flags to tweak
   the defence strength of units now; this can all be specified in the
   ruleset. (Working Unit_Defend and Unit_Firepower effects will be needed
   in the future, however; watch this space.)
3. There is partial support for impr-gen effects of governments. At the
   moment, all that is done is that the server reads the effects out of
   the ruleset. This will be used in the future for SMAC-style
   government science bonuses, etc.

        Ben
-- 
ben@xxxxxxxxxxxxxxxxxxxxxx           http://bellatrix.pcl.ox.ac.uk/~ben/
"How often have I said to you that when you have eliminated the 
impossible, whatever remains, however improbable, must be the truth?"
        - Sir Arthur Conan Doyle


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