Im trying to make a dogtag for my mana, which shows my mana if it is below 2000 mana or if I mouseover. I guess it would be something like this.
[If is mouseover then MP else if mana > 2000 then MP end]
Im not fully sure if it works, can't test atm but would be nice if someone could tell me if it is in the right direction.
[(if IsMouseOver then
MP
elseif MP < 2000 then
MP
else
nil
end)]
Just tested and that works.
Originally Posted by SiggyCertified
I am looking for a Dogtag, that turns my Health Text to a color when I am in range of a mob, 36 yards? I've tried to manipulate a few Dogtags off of this thread but nothing seems to work out, so any help would be appreciated.
The following *should* work, but I don't have RangeCheck installed to make sure. According to DogTag you'll need that lib to get any sort of range-checking working in your DogTags.
[if Range(unit="target") <= 36 then
HP:Green
else
HP:Red
end]
Originally Posted by Cady
I'm attempting to make a Dogtag that will show the percent of health a target has assuming it's not at full health or dead. Currently I'm using a Dogtag I got from Caith's Pitbull Frames
Which is just what I'm looking for except for two things, firstly I only want to show the first two numbers of the percent and nothing after the decimal (would that be the veryshort code?) and secondly I want to be able to customise the HPColors.
Not sure if you're still looking for help on this one, but just tested this and it seems to be working ok.
[Outline] [(if PercentHP = 100 then
nil
elseif PercentHP > 70 then
PercentHP:VeryShort:Percent:Green
elseif PercentHP > 35 then
PercentHP:VeryShort:Percent:Yellow
elseif PercentHP < 35 then
PercentHP:VeryShort:Percent:Red
end)]
Obviously you can spice up the text to your flavor, but the syntax is accurate and working.
Disclaimer: I'm posting these to try and get my own DogTag'n up to snuff, so if there are any errors I appologize.
[Outline][if HasCurseDebuff then "C":Color("ffffff") end]
would do the trick. Pop it to Frame, Outside Right, change the "ffffff" to whatever hexadecimal colour value you want, and you'll have an outlined C of that colour.
[if not Dead(unit="target") and (MaxRange < 40) then
"In Range":Green
elseif not Dead(unit="target") then
"Out of Range!":Red
else
"deceased":Gray
end]
If the target is in range and alive "In Range" is displayed in green else if target is out of range and alive "Out of Range" is displayed.
if the target is dead, regardless of range, deceased is displayed.
Thanks to all who generously posted their code to help me put this together
The first displays MAX when you have the highest threat on the target, regardless of who's tanking it. The 2nd displays MAX when you're tanking the target, even if someone has surpassed you in threat (within their 10% or 30% window). You can combine these two methods to something like this third option:
This is exactly like the first option above, but colored red when you've lost aggro. A yellow number means someone has passed you in aggro, but not yet pulled aggro - so it's a warning sign to step up your threat on that mob.
These DogTags look amazing. I've tried to put them into Aloft, as I would like them on my nameplates, Unfortunately I can't seem to get any tags to work besides [Name] or [Level]. Does Aloft just not support anything other than these two or am I integrating the tags in the wrong place, I've been putting them into Aloft > Name Text > Advanced > Format.
Hey everyone. I am having a problem with code for detecting Power Word: Fortitude, even when I apply the buff, the text will not go away.
It might have something to do with the fact that there's a space after the colon in "Power Word: Fortitude", but your code doesn't appear to have that space.
Been using this dogtag for target health, changing color of health when health is dropping, but I have an issue. Whenever the target has less than 5% health, the health and percent showing disappears.
Here is the dogtag:
[(if PercentHP = 100 then
nil
elseif PercentHP > 90 then
HP:Color("1AFF00") " / ":Color("1AFF00") PercentHP:VeryShort:Percent:Color("1AFF00")
elseif PercentHP > 80 then
HP:Color("64FF00") " / ":Color("64FF00") PercentHP:VeryShort:Percent:Color("64FF00")
elseif PercentHP > 70 then
HP:Color("9BFF00") " / ":Color("9BFF00") PercentHP:VeryShort:Percent:Color("9BFF00")
elseif PercentHP > 60 then
HP:Color("CBFF00") " / ":Color("CBFF00") PercentHP:VeryShort:Percent:Color("CBFF00")
elseif PercentHP > 50 then
HP:Color("FFFF00") " / ":Color("FFFF00") PercentHP:VeryShort:Percent:Color("FFFF00")
elseif PercentHP > 40 then
HP:Color("FFE900") " / ":Color("FFE900") PercentHP:VeryShort:Percent:Color("FFE900")
elseif PercentHP > 30 then
HP:Color("FFBC00") " / ":Color("FFBC00") PercentHP:VeryShort:Percent:Color("FFBC00")
elseif PercentHP > 20 then
HP:Color("FF8E00") " / ":Color("FF8E00") PercentHP:VeryShort:Percent:Color("FF8E00")
elseif PercentHP > 10 then
HP:Color("FF4300") " / ":Color("FF4300") PercentHP:VeryShort:Percent:Color("FF4300")
elseif PercentHP > 5 then
HP:Color("FF1000") " / ":Color("FF1000") PercentHP:VeryShort:Percent:Color("FF1000")
elseif Dead then
HP:Color("AAAAAA") " / ":Color("AAAAAA") PercentHP:VeryShort:Percent:Color("AAAAAA")
end)]
That'd be because there are no instructions for that health range. You'll need to add one more step using either "PercentHP > 0" or "PercentHP < 5" to cover the last few percent.
Ok, So I've been searching for a way to change some naming conventions for my Focus target Name text.
If the focus target is any one other than me, I want the naming to be class colored and size=100% If it's me, I want the size to be 300 and Bright red. Is dynamic text scaling even possible? Let me know. I'd be happy with Just a name color change, but the scaling just adds that extra pop I'm really looking for.
Thanks.
Are you using Pitbull? One thing you could do is make two dogtags. One larger and one smaller and have them along the lines of:
[if IsUnit("player") then Name:Red] for the large one
[if ~IsUnit("player") then Name:ClassColor] for the small one
Then put them in similar spots like Health bar left and Frame Inside Left. If you're using another addon you may be able to put a dogtag on top of another one (like DaHud -- I've done this a few times). You can get creative with the use of spaces and line returns within the dogtag itself to get the text pretty much in the same place in Pitbull. I bet future Pitbulls will allow more customization as far as where we can put text. I honestly use Pitbull and Dahud (with all the modules turned off aside from Text) to perfect my UI.
I play a warlock and have been trying to put together a dogtag that will show a red dot when the target is more than 36 yards away. This is my tag:
[if MaxRange > 36 then
".":Red
end]
For some reason, the red dot never appears.
Changing it to:
[if MaxRange < 36 then
".":Red
end]
Makes the red dot appear when the target is less than 30 yards away, and disappears when it's more then 30 yards away. Which is obviously wrong. I've been tinkering with it for a few hours and it's driving me nuts. Help!
I play a warlock and have been trying to put together a dogtag that will show a red dot when the target is more than 36 yards away. This is my tag:
[if MaxRange > 36 then
".":Red
end]
For some reason, the red dot never appears.
Changing it to:
[if MaxRange < 36 then
".":Red
end]
Makes the red dot appear when the target is less than 30 yards away, and disappears when it's more then 30 yards away. Which is obviously wrong. I've been tinkering with it for a few hours and it's driving me nuts. Help!
Hey, im trying to make/find a dogtag that, when i used "incinerate" it will reduce "x" by one and when "x" are used it will simply reset.
is that possible?
Hey, im trying to make/find a dogtag that, when i used "incinerate" it will reduce "x" by one and when "x" are used it will simply reset.
is that possible?
I don't think so. But if you are trying to count the number of incinerates left in your rotation before refreshing Immolate, I think you could do it by dividing AuraTimeLeft(Immolate) with the cast time of your incinerate.
[Edit] I would try something like this (disclaimer: not tested at all, may need some tweaking:
[if AuraTimeLeft(Immolate) <= 1.5 then
"Immolate":RED
else
Floor((AuraTimeLeft(Immolate)-1.5)/2.25) :ORANGE
]
It needs to be adapted to the "real" cast time of your Incinerate/Immolates, depending of your spec and your haste rating.
Last edited by Ele' : 08/20/08 at 11:28 AM.
Reason: added Tag(1), forgot some parenthesis(2), ceil!=floor(3)
You can clip our wings, but we will always remember what it was like to fly.
Simple dogtag to pull data from Threatlib:GetTPS and throw it on your unitframe for people with Threat-2.0 and the pb player threat module. I found this handy because I spend about 90% of my time staring at my unit frames watching my HP while tanking.
function HasThreat_func(unit)
if UnitIsFriend("player", unit) then
if UnitExists("target") then
return ThreatLib:GetThreat(UnitGUID(unit), UnitGUID("target")) > 0
else
return false
end
else
return ThreatLib:GetThreat(playerGuid, UnitGUID(unit)) > 0
end
end
Insert:
function TPS_func(unit)
if UnitIsFriend("player", unit) then
if UnitExists("target") then
return math.floor(ThreatLib:GetTPS(UnitGUID(unit), UnitGUID("target")) + 0.5)
else
return 0
end
else
return math.floor(ThreatLib:GetTPS(playerGuid, UnitGUID(unit)) + 0.5)
end
end
DogTag:AddTag("Unit", "HasThreat", {
code = function(args)
return HasThreat_func
end,
dynamicCode = true,
arg = {
'unit', 'string;undef', 'player'
},
ret = "boolean",
events = "Threat#$unit",
doc = L["Return True if you have threat against enemy unit or friendly unit has threat against your target and if ThreatLib is available"],
example = ('[HasThreat] => %q; [HasThreat] => ""'):format(L["True"]),
category = L["Threat"]
})
I was having a go at a dogtag for Underhood. I wanted it to show my target's name but when casting switch to the target's cast name and cast duration. Only I'm not sure exactly where to start.
I was having a go at a dogtag for Underhood. I wanted it to show my target's name but when casting switch to the target's cast name and cast duration. Only I'm not sure exactly where to start.
Something like [(CastName CastEndDuration:FormatDuration) or Name]