How to? Stop trigger causing itself to trigger..

Ellimistrox

New Member
Reaction score
10
Problem Status: Unsolved


I have made a simple critical system.
Now the event is based on this (Ignore the No Unit):

Events
Unit - No Unit Takes damage


The only problem with this is the critical system causes damage to the unit that originally takes damage.

So dealing the critical damage would cause this trigger to run all over again, with the critical damage possibly "Critting" once more.

This means that instead of critically striking once, the hero could loop several dozens critical strikes in one hit.

**If i did not explain well enough, just say!**
 

Faust

You can change this now in User CP.
Reaction score
123
Before dealing damage, turn off the trigger, after dealing damage, turn it on.
 

Ellimistrox

New Member
Reaction score
10
Hmm. Would that work even if calling a Jass function (In mapheader) between the two? (Turn off and turn on trigger)
 

Faust

You can change this now in User CP.
Reaction score
123
What is there to "not work"?
If the damaging function is in map header? Yes it will work.
 

Ellimistrox

New Member
Reaction score
10
Thanks for that, just making sure :p.
I'm not quite sure why that idea didn't hit me.
Well anyway, +Rep for being very helpful tonight :)
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top