1. #1

    weak auras to check enemies in range.

    Hi, please help me get a function to check if 2+ enemies within range so I can dot them with flame shock. It just need to show me the icon of flame shock if 2+ enemies fighting in combat.

    I have something like this but does not work:

    function(_,enemy_count )
    return enemy_count >= 3 -- or any other threshold
    end

  2. #2
    This WA looks like it will do the counting for you, fires a "WA_ENEMIES_IN_RANGE" event with the number of targets in a given radius. You could make a second WA that makes use of that information.

    However, you might want to consider a couple of possible concerns:

    1. If a target will die very soon, you probably don't want to count it. For instance, if there are 3 targets and 2 have Flame Shock, but the third will die in 4 seconds, it's probably not worth the GCD to apply Flame Shock.

    2. If all targets currently have Flame Shock applied, do you want to wait til Flame Shock falls off or do you want to reapply within the refresh range (30% of max duration)?
    Author, Hekili, a priority helper addon.

  3. #3
    TY, I do have WA_ENEMIES_IN_RANGE in event check box, but this trigger just wont go off. Please test it for me and give me xactly codes so I can have my WA running. BTW I do not care if enemies have any duration of flame shock or no flame shock on them, I just want WA to show me the icon when there r 3+ living enemies around me fighting. thx

  4. #4
    An example custom-coded trigger is here (from WeakAuras Wiki):
    https://github.com/WeakAuras/WeakAur...ippets#example

    An example WA linked from there is:
    https://wago.io/SimpleRangeChecker

    These were both pointed out to me after I spent a fair amount of time trying to find ways to be more efficient with this. Recounting targets every frame may be expensive (which is the reason there's not a default trigger for it built into WA).
    Author, Hekili, a priority helper addon.

  5. #5
    Hi Hekili, Thx a ton! that wago link is exactly what I needed! it gives some options for flexibility too, really great work there. I am just a little concerned about this add-on 's tax on my system, for what i understand it refreshes every 0.3 seconds, is it normal or very taxing?

  6. #6
    Quote Originally Posted by mmokennyc View Post
    Hi Hekili, Thx a ton! that wago link is exactly what I needed! it gives some options for flexibility too, really great work there. I am just a little concerned about this add-on 's tax on my system, for what i understand it refreshes every 0.3 seconds, is it normal or very taxing?
    That's not exceptionally CPU intensive. You'll see many WAs written that update "Every Frame" which means they could execute 60 times per second or more (literally, whatever your frame rate is).

    Also, that aura wasn't my work -- just what I was directed to from the WA Discord and the wiki. Thank asakawa for that.
    Author, Hekili, a priority helper addon.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •