| 05-01-2004, 04:59 AM | #1 |
This spell detects if a certain hero is the target of a spell. It works simarly to amulet of spell-blocking, but it has a percentage chance to reflect the spell as well. The reflection works by creating a dummy unit, giving that unit the ability that was cast on the hero, and ordering the dummy unit to cast it upon the casting hero. (the SpellString variable replaces the "night elf dryad - abolish magic" order in the custom text, giving the appropriate order string) It works fine. The problem is this: when the spell is copied to the dummy unit, it will only be lvl one. If a lvl 5 spell is cast on the hero, the dummy unit will only inherit the spell at level one. Oblviously, this works fine for unit abilities, but not hero abilities. Is there any way to fix this? I've been looking for a solution for hours now, but have found none. Any ideas? I sure hate to have to scrap this after all my work on it... :( |
| 05-01-2004, 09:19 AM | #2 |
You can learn the abillity with triggers. It's the hero - learn abillity. For A from 1 to (level of <spell> for casting unit - 1)-->Already one level learned learn <spell> for <your caster> |
| 05-01-2004, 01:34 PM | #3 |
Unfortunately, that won't work... A unit can only learn a spell this way if it already has that spell (as in, the ubit had the spell in the World Editor). This was actually one of the problems I had awhile ago when I was working on another project. The only way I know of to do this is to make a unit ability for each level of the spells and give that to the Dryad. What your looking for, I believe, is a set skill level trigger which Blizzard, for some reason, never included. Sorry I can't be of more help... -Shimrra |
| 05-01-2004, 03:23 PM | #4 |
Ah, ok. Shoot. I was afraid of that. I'll redo the skill then. Maybe instead of reflecting spells, the hero will have its own retalitory spell of some sort. Thanks for the input though. |
