[CF-Devel] New god_intervention()

Jan Echternach echter at informatik.uni-rostock.de
Wed Nov 8 14:37:41 CST 2000


Hi,

First what this patch does outside of god_intervention():

The problems with start equipment (cursed items, many spellbooks with
same spell) should be fixed.

"summon avatar" is probably broken, because it used the god itself as
the archetype to clone, and that has now some randomitems that the
avatar should not have.  But once the patch doesn't need to care about
compatibility anymore, it'll be trivial to make a seperate avatar
archetype and record the name of this archetype somewhere in the god's
treasure list.

A bug in god_intervention() has been fixed.  Depletion was always
removed even if the god had attacktype & (AT_DRAIN | AT_DEPLETION)
because the code did test for attacktype & (AT_DRAIN || AT_DEPLETION).
Well, you'll find this is the kind of bug when you a) look _very_
carefully, or b) put spaces before and after operators.

god_intervention() now looks at the god->randomitems if the god has
some.  I've already implemented some new possibilities.  You need to
follow Mostrai if you want to test them with this patch.

There's still a lot of compatibility code left.  I'd like to remove
that code ASAP, but that requires that every god has a treasure list.

What's different from old god_intervention() except that you can now
select each feature independently from each other and independently
from god's path_attuned/repelled/denied:

* Distinct "remove damnation", you can have gods that only remove
curses, not damnations.

* Some gods may enchant weapons better than other gods (determined by
the level of the treasure object).  I've also reduced enchantments at
high wisdom levels.  Even a god with god_enchant_weapon_high will only
enchant weapons to magic +11 (if follower has maximum wisdom level).

* Weapons will get a title first, before everything else.  Gods will
never add an attacktype to a weapon without that title.

* (Not yet in this patch, but in my sources:) God will add its
attacktypes if weapon has some of the attacktypes, but not yet all.

* God can give any treasure (from a treasure list in the "treasures"
file) to the follower.  FLAG_STARTEQUIP will be set on these items.  Be
careful when using this feature, because the amount is not limited.
Example in the patch: random_food.

* God can give any item (with or without FLAG_STARTEQIUP) to the
follower.  It won't hand out this item if the follower already has
something similar.  This makes it rather safe to use.  Example in the
patch:  Helmet of Mostrai.

* God can say arbitrary messages.

* God gives spells to the follower.  In addition to what was already
implemented (directly teaching the spell), the god can also give a
spellbook with that spell.  The new code doesn't use
learn_prayer_chance[] anymore, because the calls to god_intervention()
are already influenced by the followers wisdom, and it turned out that
the only limiting factor was the level (because once I had reached the
required level, I went to an altar, started praying, put some heavy
item on the 'use_skill praying key and just waited until I got the
spell).

Possible features not implemented:

* There is only the possibility to completely heal the follower.
Some gods (e.g. those with path_repelled & PATH_RESTORATION) could
use a less powerful healing method.

* There is no possiblity to restore spellpoints implemeted yet.

* Enchanting of bows and other types of equipment.

What's needed now is discussing these and other ideas, and creating the
treasure lists for the other gods.  I'd appreciate if somebody else
would create these lists.  All required features and standard
archetypes to replace the old god_intervention() are already in this
patch, you'd only need to create archetypes for the spells and put the
treasure lists in lib/treasures.  Then I can remove the compatibility
code and make the patch ready for inclusion in the official CVS tree.

-- 
Jan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch38a.gz
Type: application/x-gunzip
Size: 9199 bytes
Desc: not available
Url : 
     
     http://shadowknight.real-time.com/pipermail/crossfire/attachments/20001108/a08f5a72/patch38a.bin
     
     
-------------- next part --------------
A non-text attachment was scrubbed...
Name: arch38a.gz
Type: application/x-gunzip
Size: 1128 bytes
Desc: not available
Url : 
     
     http://shadowknight.real-time.com/pipermail/crossfire/attachments/20001108/a08f5a72/arch38a.bin
     
     
    


More information about the crossfire mailing list