| 12-26-2006, 06:13 AM | #2 |
It's because you're using the "Target unit of ability being cast" function to refer to a unit after a wait command. The problem is that after any sort of a wait command, only the "Triggering Unit" function and variable references work. I suggest you use a local variable in order to be able to refer to the unit, so the trigger would look something like this: Trigger: Mana Slash
![]() Actions
![]() ![]() Custom Script: local unit udg_Mana_Slash_Target
![]() ![]() Set Damage = 0.00
![]() ![]() Unit - Turn collision for (Triggering unit) Off
![]() ![]() Special Effect - Create a special effect attached to the weapon, right of (Triggering unit) using Abilities\Weapons\SpiritOfVengeanceMissile\SpiritOfVengeanceMissile.mdl
![]() ![]() Set MS_FX[1] = (Last created special effect)
![]() ![]() Special Effect - Create a special effect attached to the weapon, left of (Triggering unit) using Abilities\Weapons\SpiritOfVengeanceMissile\SpiritOfVengeanceMissile.mdl
![]() ![]() Set MS_FX[2] = (Last created special effect)
![]() ![]() For each (Integer A) from 1 to (((Level of Mana Slash for (Triggering unit)) x 2) + 2), do (Actions)
![]() ![]() ![]() Loop - Actions
![]() ![]() ![]() ![]() If (All Conditions are True) then do (Then Actions) else do (Else Actions)
![]() ![]() ![]() ![]() ![]() Then - Actions
![]() ![]() ![]() ![]() ![]() ![]() Set Damage = (Damage + ((Mana of (Triggering unit)) x 0.05))
![]() ![]() ![]() ![]() ![]() ![]() Set MS_Target_loc = (Position of (Mana_Slash_Unit))
![]() ![]() ![]() ![]() ![]() ![]() Unit - Move (Triggering unit) instantly to MS_Target_loc
![]() ![]() ![]() ![]() ![]() ![]() Animation - Play (Triggering unit)'s attack animation
![]() ![]() ![]() ![]() ![]() ![]() Special Effect - Create a special effect attached to the chest of (Mana_Slash_Unit) using Abilities\Spells\Other\Charm\CharmTarget.mdl
![]() ![]() ![]() ![]() ![]() ![]() Special Effect - Destroy (Last created special effect)
![]() ![]() ![]() ![]() ![]() ![]() Unit - Cause (Triggering unit) to damage (Mana_Slash_Unit), dealing Damage damage of attack type Hero and damage type Normal
![]() ![]() ![]() ![]() ![]() ![]() Custom script: call RemoveLocation(udg_MS_Target_loc)
![]() ![]() ![]() ![]() ![]() ![]() Wait 0.32 game-time seconds
![]() ![]() Custom Script: set udg_Mana_Slash_Unit = nullThat should do it, and if you don't understand the local variable thing, make sure you read this guide on MUI (Multi-user instanceablity, which is something that this spell also lacks). |
| 12-26-2006, 06:44 AM | #3 | ||
Quote:
Wow. I knew about the triggering unit being able to work after a wait, but not the target unit of ability being cast NOT being able to be used after a wait. Thanks! Quote:
Don't worry, I understand the local variable thing I usually always make my spells in GUI, then make them 100% MUI later on. Thx for your help! |
| 12-26-2006, 06:56 AM | #4 |
Yup, only "Triggering Unit" works after a wait. Goddamnit the WE for it working that way. I work the same way you do, and I'm glad I could help out |
