• 0

    posted a message on LuaTexts Official Thread
    Quote from evergamer
    well, damn, i guess i wasnt done.

    here is what i have for target's health:

    local s = Status(unit)
    if s then
      return s
    end
    local cur, max = HP(unit), MaxHP(unit)
    local r,g,b = HostileColor(unit) 
    return "|cff%02x%02x%02x%s/%s %s%%|r",r,g,b,cur,max,Percent(cur,max)
    it displays as 12345/12345 100%

    I would like it to display as 12.3k/12.3k | 100%

    I tried entering the Short tag in some spots to no avail. I am just clueless when it comes this code. I really appreciate the help. Any suggestions?


    Try replacing "cur,max" in the return line with "Short(cur,true),Short(max,true)" assuming I understand how Short() needs to format its return.
    Posted in: Unit Frames
  • 0

    posted a message on LuaTexts Official Thread
    Quote from sfan27
    tzirean: You don't need to define icon from UnitAura() since you don't use it, not that it really hurts much of anything. Also, you should add "HELPFUL" to your UnitAura() call. Also, that SetFormated is going to produce some garbage from what I remember Shefki saying.


    Cool, thanks for the info. I was just assuming the code he'd posted worked right, and that all that was necessary was to strip out the stuff he didn't want.
    Posted in: Unit Frames
  • 0

    posted a message on LuaTexts Official Thread
    Quote from Snargul
    Thanks for those who helped me before. Since I don't want to register for EJ just for this, how do I make this show only my Renew/PoM?


    If I'm not mistaken, this should work:

    local i = 1
    local renew,mending = false,false
    while true do
      local name,_,icon = UnitAura(unit,i)
      if not name then
        break
      elseif name == "Renew" then
        renew = true
      elseif name == "Prayer of Mending" then
        mending = true
      end
      i = i + 1
    end
    Outline()
    return "%s%s",renew and "|cff00C000.|r" or '',mending and "|cff00C5CD.|r" or ''
    Posted in: Unit Frames
  • 0

    posted a message on PitBull 4.0
    Quote from sfan27
    tzirean: You need to control the Events which trigger changes. For example, the two tags I created need the UNIT_AURA event.


    Ha. Go me. I didn't have any Events set for any of my custom texts.

    I just jumped 99% of the way toward being finished with my layout. Thanks so much for your help.
    Posted in: Unit Frames
  • 0

    posted a message on PitBull 4.0
    Quote from sfan27
    tzirean: If it isn't working atm I have absolutely no idea. Try recopying the code from my original post. It works exactly as advertised for me.


    Actually, I no longer think the code is the problem. I took PitBull4 for a spin in a raid setting last night and I noticed that none of the texts were updating; for example, while the bars would move, the only way I could get the target frame to change the HP/MP info text was to deselect and reselect the target, while my player frame maintained my pre-buff values. This is using the latest release version. I'm going to download the latest beta when I get a chance and see what changes.
    Posted in: Unit Frames
  • 0

    posted a message on LuaTexts Official Thread
    Quote from sfan27
    That shouldn't be the issue. It would return BROKEN! if that were true. The issue definitely lies in the Dead() check.


    It is returning BROKEN! :) :

    Quote from tzirean »
    the sheep text only ever displays "BROKEN!"
    Posted in: Unit Frames
  • 0

    posted a message on LuaTexts Official Thread
    Quote from sfan27
    Yeah, sorry about the HARMFUL/HELPFUL mistake, I was wiriting that code in a hurry before I left for the evening. It is fixed in the original post, but I don't get the sheep problem either.


    No, totally understood, I should have noticed it long before I did, too.

    As for the sheep text, it seems like it's never setting poly to true, but I have no idea why; everything looks like it should work.
    Posted in: Unit Frames
  • 0

    posted a message on LuaTexts Official Thread
    Quote from tzirean
    Neither one seems to work, sadly. They don't give any errors, but the sheep text only ever displays "BROKEN!" while the buff text never displays anything.


    Looking at them today, I got the buff one to work, seemingly: every instance of HARMFUL should be HELPFUL. Still not sure why the sheep one doesn't work.
    Posted in: Unit Frames
  • 0

    posted a message on LuaTexts Official Thread
    Neither one seems to work, sadly. They don't give any errors, but the sheep text only ever displays "BROKEN!" while the buff text never displays anything.
    Posted in: Unit Frames
  • 0

    posted a message on LuaTexts Official Thread
    I've been working with a lot of success converting my DogTags to LuaTexts, but I can't wrap my mind around the commands for auras and buffs, so I'm stuck on converting the last two. Could someone give me a hand, please?

    [Outline][(if HasAura("Polymorph") and (AuraDuration("Polymorph") <= 5) then
        "Resheep!":Yellow
    end) (if HasAura("Polymorph") and (AuraDuration("Polymorph") > 5) and (AuraDuration("Polymorph") <= 10) then
        "Soon!":Green
    end) (if HasAura("Polymorph") and (AuraDuration("Polymorph") > 10) and ~Dead then
        "Sheeped":Cyan
    end) (if ~HasAura("Polymorph") and InCombat(unit="player") and ~Dead then
        "BROKEN!":Red
    end)]
    and

    [Outline][(if (Class(unit="player") = "Mage") and HasAura("Arcane Brilliance") then
        ".":Cyan
    end) (if (Class(unit="player") = "Mage") and HasAura("Dalaran Brilliance") then
        ".":Cyan
    end) (if (Class(unit="player") = "Mage") and HasAura("Arcane Intellect") then
        ".":Blue
    end) (if (Class(unit="player") = "Mage") and HasAura("Dalaran Intellect") then
        ".":Blue
    end) (if (Class(unit="player") = "Priest") and HasAura("Prayer of Fortitude") then
        ".":White
    end) (if (Class(unit="player") = "Priest") and HasAura("Power Word: Fortitude") then
        ".":Gray
    end) (if (Class(unit="player") = "Priest") and HasAura("Prayer of Shadow Protection") then
        ".":Red
    end) (if (Class(unit="player") = "Priest") and HasAura("Shadow Protection") then
        ".":Fuchsia
    end) (if (Class(unit="player") = "Druid") and HasAura("Gift of the Wild") then
        ".":Yellow
    end) (if (Class(unit="player") = "Druid") and HasAura("Mark of the Wild") then
        ".":Green
    end)]
    Yes, I'm aware that last one is horrendously inefficient, but I generally had to sacrifice "efficiency" for the sake of "not getting a Syntax error." I've gotten that if (Class(unit="player") = "Mage" is now the simpler if Class('player') == 'Mage', but I've always been a poor programmer and trying to figure out UnitAura and the like is breaking my brain. Any help is appreciated.
    Posted in: Unit Frames
  • 0

    posted a message on AuldLangSyne Replacement/Continuation
    Quote from Phanx
    1. Do you have Lua errors enabled, or an error handling addon like BugSack installed?
    2. There isn't a native configuration screen. Try typing "/als" in-game.
    3. Make sure the addon is enabled at the character selection screen, and that you have the "Load out of date addons" checkbox checked. Sounds obvious, I know, but you'd be surprised at how many people post "addon X doesn't work!" when they haven't checked that checkbox.


    1. Yeah. Never seen an ALS-related error.
    2. Nothing.
    3. Yeah, I do. Toggled it off and back on just in case, no change.

    I'm not terribly concerned about it; I figured it was broken and that was that. I just check every so often, when I update my other addons, to see if it's been fixed or if there's a new and improved addon.
    Posted in: Addon Ideas
  • 0

    posted a message on AuldLangSyne Replacement/Continuation
    Quote from Phanx
    You know, if you people could somehow bring yourself to be more descriptive than "it doesn't work", someone might actually be able to help you figure out how to fix the problem...


    I know, but there really isn't much to be descriptive about. There are no errors, can't pull up any configuration screen, the ALS data just doesn't display on my friends list.
    Posted in: Addon Ideas
  • 0

    posted a message on AuldLangSyne Replacement/Continuation
    Quote from Phanx
    AuldLangSyne works fine for me, although I don't use the FuBar plugin. Is there some part of it that isn't working, or are you just panicking because there hasn't been a .toc update?


    AuldLangSyne hasn't worked for me since 3.0.2. I don't use the FuBar plugin, either. I had no idea it was working for some people.
    Posted in: Addon Ideas
  • 0

    posted a message on Parrot 1.0 Beta for the 2.4 combat log
    Is there any way to get a working trigger for Shamanistic Focus? It's a shaman ability (11-point Enhancement) that causes the Focused buff (found here). Focused does come up in the buff column, but I'm not usually paying as much attention to that part of the screen unless I specifically have to watch for something; it'd be great if it could pop up a trigger like Execute and Nightfall do. Thanks.
    Posted in: General AddOns
  • 0

    posted a message on Help me fix these DogTag lines please!
    Here's another one confusing the utter hell out of me.

    In my CowTip, I have [(TalentTree ? TalentTree:Hide("None"):ClassColor " ") (IsPlayer ? Class:ClassColor)]. Works fine for other players; if they have a TalentTree, I get "Human Holy Paladin" or "Undead Fury Warrior" or whatever. If they don't, I get "Human Paladin" and "Undead Warrior." However, for myself, I get no TalentTree (neither PitBull nor CowTip recognizes my own tree or spec, in fact) and I get an extra space, so it reads "Human Mage." Highly annoying, and the tag above is my fifth try at getting rid of the extra space, but I haven't managed to get rid of the space and still show TalentTree.
    Posted in: AddOn HELP!
  • To post a comment, please or register a new account.