Posted 24 July 2006 - 07:47 AM
A couple of corrections/additions:
AI_SPELLBOOK_ALWAYS_FIRE: this has nothing to do with increasing fire, it simply triggers the ability everytime the cooldown is over. I use it for warg howl and goblin poison blades in my mod.
AI_SPECIAL_POWER_CAPTURE_BUILDING: this simply enables a AI unit to capture buildings like outposts/inns, when it is near them.
AI_SPELLBOOK_STRUCTURE_BASEKILL: don´t use this for spells that can´t be targeted directly on buildings(like the balrog), the AI will often try to cast that spell directly on top of the building, so it won´t work unless the building gets destroyed some other way.
AI_SPELLBOOK_STRUCTURE_BREAKER_PREF_WALLS : Similar to the above that doesn´t work well. You can witness that this doesn´t work well sometimes with an elven AI. It often summons ents directly after a fortress goes down on the spot where the fort used to stand. Works pretty fine for wyrms though.
This is probably the most useful one. It works great for everything where you want to target a bunch of enemy troops with an ability that has a good range. In my mod I use it for dragon teleport, balrog wings, ranger longshot and the fortress abilities like wizard tower/gorgoroth spire.
This seems to trigger when the unit is on roughly half health, not when it is surrounded so for boosts with a rather low cooldown, you may rather want to use always_fire.
SpecialPowerRadius : My testing suggests that this is actually a range parameter, which determines how far the target unit can be away from the casting unit.
So for abilities that are used in close combat you want a very low radius, e. g. wormtongue´s backstab has 50 and works, whereas morgulblade has 100 basegame and doesn´t seem to work.