• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Need a JASS function

Status
Not open for further replies.
Level 5
Joined
Aug 23, 2007
Messages
141
I've just only started using JASS, so you could say I'm noob at this. I just need to know how to remove an event from a trigger if it is possible. You know... what function is used? A spell I'm working on consists of two JASS triggers. The first one adds an event to the second one. But to prevent leaks I think I have to remove the event after the second trigger runs. How do I do this? BTW. How do you also limit a trigger so that it will only read the "recieves damage" event if the damage is from an attack?
 
Last edited:
Level 22
Joined
Feb 26, 2008
Messages
891
> I think I have to remove the event after the second trigger runs.

I don't think you need to do that. As far as I know, events do not leak.

> only read the "recieves damage" event if the damage is from an attack?

As far as I know, this is impossible. The only way to do what you want would probably involving writing your own damage detection system, which is a lot of work.
 
Level 5
Joined
Aug 23, 2007
Messages
141
Ouch. :p Well is it possible to only read the "receives damage" trigger with particular attack types? (siege, hero, normal, etc.) that way it will only detect damage if the damage source has a Hero, Normal, or piercing attack.
 
Status
Not open for further replies.
Top