• 0

    posted a message on LuaTexts Official Thread
    So I'm using this code to display mini health values when a raid member is missing health. How can I get it to display "dead"/"ghost" in place of a numerical value, but without the timer? Thanks!

    local s = Status(unit)
    if s then
      return s
    local cur, max = HP(unit), MaxHP(unit)
    if UnitIsFriend(unit,"player") then
      local miss = max - cur 
      if miss ~= 0 then
        return "|cffffacac-%s|r",VeryShort(miss,true)
        return ''
      return "%s/%s",VeryShort(cur,true),VeryShort(max,true)

    Edit: joined an AV that was in progress and saw this odd behavior:

    As you can see, the health display is behaving properly for players nearby, such as the shaman in the bottom right. The far away ones have a strange bug in that it displays the minus sign twice and reflects a seemingly nonexistent deficit. Not sure how to clean that one up.
    Posted in: Unit Frames
  • To post a comment, please or register a new account.