Progress Bar - how can I get "source"?

  • 4 posts
    #1 May 09, 2011 at 02:06 UTC - 0 likes

    How would I go about getting the source of a spell (IE Dark Intent) on a Progress Bar?

    I want the text on the progress bar to read something like "%n (%source)" (example: "Dark Intent (Billy)").

    #2 May 09, 2011 at 03:14 UTC - 0 likes

    @JStrese: Go

    You mean the caster of the spell? There is no way to do that at the moment, but it's an interesting idea. I'll try to think of ways it can be implemented.

    #3 May 09, 2011 at 03:51 UTC - 0 likes

    @Mirrormn: Go

    Yep, that's what I meant :(

    #4 May 09, 2011 at 04:04 UTC - 0 likes

    I suppose you could use a "%c" custom text and then define Custom Text Function such as this:

      local _, _, _, _, _, _, _, unitCaster = UnitBuff("player", "Dark Intent");
      return UnitName(unitCaster or "") or "unknown";

    That would be rather inefficient, though, since Custom Text Functions currently update every frame, and UnitAura calls are fairly heavy.

    Last edited May 09, 2011 by Mirrormn
  • 4 posts

You must login to post a comment. Don't have an account? Register to get one!