| 08-18-2004, 01:30 AM | #1 |
Hey, I got two questions... and my take on them. 1. AOE detection. Here's the scenario: TC casts shockwave, which is a spell that does damage according to a combination of his STR attribute and INT attribute. (ie, a formula like, 100 damage + (STR * 3 + INT * 2) damage to every unit affected by the shockwave) How would you go about doing that? My problem is, how would you detect which units in a "region" are affected by the shockwave. (I'm not sure how to dynamically create a rectangular region of the right size... ) 2. Re-creation of Chain Lightning, because it's doing variable damage. This is similar to the first problem. Envision a chain lightning that does variable damage based on the caster's intelligence, strength, and so on, for each target. I was going about to re-create chain lightning using dummy spells/casters. Basically the algorithm was similar to this: Caster casts "new" chain lightning (which does NO damage and only hits one target) on target Create dummy caster on first target Calculate/deal damage on first target Select next target within range of caster *** Use dummy caster to cast "new" chain lightning on next target *** Move dummy caster onto second target Calculate/deal damage on second target Select next target within range of caster *** Use dummy caster to cast "new" chain lightning on next target *** .... repeat ... My problem is, I can't do the *** step. That is, I can't select the "new" chain lightning... I can only select the base-ability and not it's derived one. *EDIT* Oh, I guess I forgot to mention, I'm a bit reluctant to change the original spells - I know that's a solution. I could change the original chain lightning and make it hit one target only, and do 0 damage, etc. But I would like to avoid that if possible. (Talking about: IssueTargetOrderBJ ( ... , SpellOrder, ...)) Can anyone help me with this? I hope I explained it clearly enough. Thanks |
