• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Leak/Efficiency check

Status
Not open for further replies.
Level 4
Joined
Jul 23, 2007
Messages
129
Hey guys. I'm starting to train myself how to avoid/deal with leaks. Please tell me if the following trigger leaks or not. Also, please tell me if it is MUI or not.

Also, please let me know if there is anything I can do to make the trigger better.

Just so you know, this spell makes the caster ethereal and heals them for x hit points over 10 seconds (via dummy units casting rejuv and banish).

  • Accursed State
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Accursed State
    • Actions
      • Set Temp_Point = (Position of (Triggering unit))
      • Unit - Create 1 UNIT_ACCUR_DUMMY[(Level of Accursed State for (Triggering unit))] for (Owner of (Triggering unit)) at Temp_Point facing Temp_Point
      • Unit - Add a 3.00 second Generic expiration timer to (Last created unit)
      • Unit - Order (Last created unit) to Human Blood Mage - Banish (Triggering unit)
      • Unit - Create 1 UNIT_ACCUR_DUMMY[(Level of Accursed State for (Triggering unit))] for (Owner of (Triggering unit)) at Temp_Point facing Temp_Point
      • Unit - Add a 3.00 second Generic expiration timer to (Last created unit)
      • Unit - Order (Last created unit) to Night Elf Druid Of The Claw - Rejuvenation (Triggering unit)
      • Custom script: call RemoveLocation (udg_Temp_Point)
EDIT: I fixed the facing unit location leak. Thanks marven15.
 
Last edited:
Level 6
Joined
Jan 17, 2007
Messages
177
I used Leak Check. It says your leaking two locations. I'm talking about "Temp_Point" facing (Position of(Triggering Unit))".
 
Level 6
Joined
Jan 17, 2007
Messages
177
I also experienced that. Did you downloaded the 3.1 version? If you downloaded it, Download the 3.0 version. That will work.
 
Level 4
Joined
Jul 23, 2007
Messages
129
Leak check doesn't work for jass because it checks for things that leak and recommends fixes, in Jass there aren't fixes because you shouldn't have code that leaks
 
Level 4
Joined
Jul 23, 2007
Messages
129
Just because I'm working in GUI, that doesn't mean that I don't want my triggers to be as efficient as GUI will allow. I enjoy map-making, but am not really inclined to put in the effort to learn JASS.

Despite popular opinion: Functional, Fun, and lag-resistant maps can be made in GUI.
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
Just because I'm working in GUI, that doesn't mean that I don't want my triggers to be as efficient as GUI will allow. I enjoy map-making, but am not really inclined to put in the effort to learn JASS.

Despite popular opinion: Functional, Fun, and lag-resistant maps can be made in GUI.

I'm happy for you that you enjoy making maps.
Anyway, of course good maps can be made with GUI, but most of the stuff you will want to make MUI (can be cast by any unit, any time, without bugging anything) is almost impossible.
And Jass will always be better at coding more efficient codes.

Now about the subject itself, you might as well just learn what leaks are instead of using a leak checker (which is not always right if I remember correctly).
You can read this little explanation I made or find many other explanations.
 
Level 4
Joined
Jul 23, 2007
Messages
129
Yea, I've been studying up on leaks with tutorials/etc.

Is the trigger above MUI? I would think that it is since Temp_Point is set and cleared in the same trigger, so it would be reset and re-cleared each time the ability is used.

Also, my answer to the MUI issue is to make abilities semi-MUI. By using arrays, If can make abilities able to be cast by 1 unit/hero for each player simultaneously. I just have to be careful that the effect of the spell is not longer than the cooldown. This limits me to hero arena/maul/aos/etc type maps, but I'm cool with that. Once I get really good at GUI, I might consider learning JASS. Not yet, though. :)

I'm still discovering useful GUI functions that I didn't know existed on a weekly basis.
 
Level 4
Joined
Jul 23, 2007
Messages
129
I can't find JassNewJenPack in the tools section. Were can I find it? Also, can I/should I use it without any knowledge of Jass?

Also, is the trigger in the original post MUI?
 
Level 4
Joined
Jul 23, 2007
Messages
129
I thought from a programming standpoint that is was impossible for any two triggers to occur at exactly the same time.

Oh, and good to 'see' you again redscores. I hope to run into on b.net sometime.
 
Status
Not open for further replies.
Top