• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!

(Need some triggering help)

Status
Not open for further replies.
Level 4
Joined
Oct 4, 2005
Messages
65
Events
Unit - A unit Finishes casting an ability
Conditions
(Ability being cast) Equal to Moral Drop
Actions
Unit - Kill (Triggering unit)

What I am trying to do is whenever I click the ability (On the unit) it kills it self and I do not wan't this. I wish for the unit to -die when the ability `Stops` or `Finishes casting` not when I just clicked to start the casting.

Whats wrong here..
 
Level 6
Joined
Feb 18, 2005
Messages
263
then do it a little different:

event:
same
condition:
same
action:
unit - add a 0.25 second expiration time to (casting unit)
that way the unit has 0.25 seconds to cast the spell and will die directly afterwards.
it works for me - i'm using this too ^^
 
Level 4
Joined
Oct 4, 2005
Messages
65
Actions
Unit - Add a 0.25 second Generic expiration timer to (Triggering unit)
Unit - Kill (Triggering unit)

Okay. I did this and the unit still dies.

Or should the Action look like this?

Actions
Unit - Add a 0.25 second Generic expiration timer to (Triggering unit)
 
Level 4
Joined
Oct 4, 2005
Messages
65
Okay it seems by removing the

Actions
Unit - Add a 0.25 second Generic expiration timer to (Triggering unit)
Unit - Kill (Triggering unit)

And by leaving just the what is in yellow the unit still dies.

Let me try to be more clear about what my goal here is.

I am using "Immolation" ability to be casted on a unit to drain the mana. Once the mana has been drained, a trigger will run and kill the unit for the mana being drained. Now, I do not wish for the unit to die once I first click the ability and the mana has not been drained.
 
Level 6
Joined
Feb 18, 2005
Messages
263
then you might to the trigger a little different:

1st possibility
modify
set the time for the expiration timer = the time required to drain the mana.

2nd possibility
remake
Once you cast imolation on a unit, set it's custom value = 1
Once you stop, set it = 0
Run a trigger:
'every 1 second' - 'pick every unit matching - custom value(matching unit) = 1' - 'if mana = 0 then kill picked unit'


thats the easiest (or at least fastest to explain) triggers.
alternativly you can do some jass, but i'll not type down the trigger - GUI should be enough.

- Raszul
 
Level 4
Joined
Oct 4, 2005
Messages
65
Events
Unit - A unit Stops casting an ability
Conditions
((Ability being cast) Equal to Moral Drop ) and ((Mana of (Triggering unit)) Equal to 0.00)
Actions
Unit Group - Pick every unit in (Units in (Playable map area)) and do (Unit - Kill (Triggering unit))

This is the only thing I could come up with for what you have wrote.
 
Level 4
Joined
Oct 4, 2005
Messages
65
Thank you for all your efforts to help, I have found away around this problem. I am no longer up the creek without a patle. Instead of using a 'trigger' that takes brains to figue out, I instead finaly found a ability that could offer the same idea and I used it. It only took me 2 days to find out how to edit the abilitys to where they function to where I wan't them.

Its not perfect, but it will have to do for now.

Again - Thank you for your efforts they are most helpful although did not get anywhere.

-Nydedrigan.
 
Status
Not open for further replies.
Top