Shadowed Unit Frames

618 - custom tag set to update every frame only updates when the unit of its frame changes

I made this minimal example and tested it with a new SUF profile ("Enable frequent updates" checked and "Update interval" set to 0).

function(unit, unitOwner)
  if not sufTagRangeInvocations then sufTagRangeInvocations = 0 end
  sufTagRangeInvocations = sufTagRangeInvocations + 1
  return string.format("%d", sufTagRangeInvocations / 60)
end

I'd expect it to display a number that is incremented from 0 roughly every second (at 60 fps) while the tag is shown on some frame. What actually happens is that (after UI reload, login, etc.) the text won't change at all on it's own (when I display it on my target and change targets a lot it will eventually increment). This apparently can be fixed by changing the tags code in some (cosmetic) way and saving it again (until the next UI reload).

I took a very crude look at tags.lua and found that, when I invoke updateMinimumFrequency() manually from within the game (after having removed the local keyword from it's declaration), the tag starts working as expected.

I'm using version 3.8.9.

Hope you got time to look into this and thanks for developing this great addon, Meribold

User When Change
Shadowed Nov 11, 2013 at 02:54 UTC Changed status from Accepted to Invalid
Shadowed May 29, 2013 at 16:43 UTC
meribold May 26, 2013 at 20:43 UTC Create

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

  • 2 comments
  • Avatar of Shadowed Shadowed Nov 11, 2013 at 02:55 UTC - 0 likes

    This is not a bug. It's due to scopping of variables. ShadowUF.count will correctly increment.

  • Avatar of Shadowed Shadowed May 29, 2013 at 16:43 UTC - 0 likes

    I'm probably not going to have time to look into this for a while since it looks like it's not something many people use. It's most likely an issue with the frequency caching not quite working.

  • 2 comments

Facts

Last updated
Nov 11, 2013
Reported
May 26, 2013
Status
Invalid - This was not a valid report.
Type
Defect - A shortcoming, fault, or imperfection
Priority
Medium - Normal priority.
Votes
0

Reported by

Possible assignees