#Issue trying to make progress bar for Tyrande's Favorite Doll

19 messages · Page 1 of 1 (latest)

lyric grove
#

When the trinket Tyrande's Favorite Doll is equipped, every time you cast a spell you gain the buff Recaptured Mana that holds up to 4200 points of mana. I'm trying to make a progress bar that shows the percent of mana recaptured (out of 4200) but I can't get the information or for the bar to progress currently. In Display I have Orientation set to Right to Left, Inverse checked, and Progress Source set to Manual with "Set Maxmium Progress" set to 4200. Trigger is set to Aura > Player > Buff, Exact Spell ID is set to 92596 (the ID of recaptured mana), Own Only is checked, and I've tried Shown On set to Always and set to Aura(s) found. Is there something I'm missing to do it?

trim maple
#

Don't use exact spell ID, just put the ID into "names" in the trigger

#

Click "fetch tooltip info" in the trigger

#

Then in the display tab for progress source set it to trigger 1 -> tooltip1

#

And yeah, set max to 4200

lyric grove
#

ahh ok, thanks!

trim maple
#

Using exact spell ID is only very rarely relevant, and it'll fail if you got the wrong one on accident.

And yeah, it needs to know where to get the progress info from. If you set it to manual like you did, then you'd have to manually assign values.
But with "fetch tooltip info" you can use the first number found in the tooltip (tooltip1), which in this case is the stored mana

lyric grove
#

thanks, that makes perfect sense

#

yep, all of that fixed it!

#

one last thing - I remember in wrath there was a page floating around in a weakaura wiki (on github maybe?) about tips and tricks, and one of the tricks was a custom function to show percent value in a progress bar. Do you happen to know where that page is now? I couldn't find it but would like the bar to show % of mana filled

trim maple
#

Click on the ⚙️ (says "format" next to it) near the text in the display tab

#

Check if there's a way to format it as % by default

lyric grove
#

not that i can see

#

I see %p/%s which look the closest but they give the actual value or nothing

trim maple
#

If it's not there, then change your text to %c. Go to the custom text function, put in:

function()
    if aura_env.state and aura_env.state.tooltip1 then
        return (aura_env.state.tooltip1 / 42) .. "%"
    end
end
#

It could be that it throws an error if tooltip1 is actually a string and not a number

#

We'll see. If that's the case then that's easy to fix though

lyric grove
#

thanks, thats the function I was thinking of. Will give that a go, and if its a string yeah thats an easy cast

#

yep that worked great, only change I had to make was floor the result