- Registered User
Member for 12 years, 1 month, and 25 days
Last active Fri, Oct, 4 2013 14:32:22
- 0 Followers
- 241 Total Posts
- 0 Thanks
Jul 2, 2009Posted in: Unit FramesQuote from DreadxSince it occurrs in 25-mans but not in 10-mans (at least not that I notice), and it occurrs with only self and target frames showing, I am going to guess it has to do with the auras. I wasn't able to do much testing tonight (want to run with auras off and see what happens), but will try and test it tomorrow. Has anyone else experienced similar issue/behavior?
A lot of this is what Shefki has been working to eliminate.
Are you still using DogTags?
I just notice you say it works when you have only two frames showing. Have you set up *any* other frames for the other people in your group/raid?
Do you have a solid state drive?
Jun 29, 2009What witchcraft is "SeparateDigits()"?Posted in: Unit Frames
I looked through the Lua reference manual, the LuaText page, the api page at wowprogramming, and the wowwiki.com/api page.
I call shenanigans.
(i.e., what are other resources I can use to figure out more stuff on my own?)
Jun 19, 2009Posted in: Unit FramesQuote from Kerecha
Btw would this code be able to handle Rare Elites, or will it just stop at the first "match" ?
Please consider looking up how "if...then...else" conditionals work. A grasp of that will help you get a better idea of how to make some of the things you're looking at.
(Of course also determine the difference between "else" and "elseif".)
Jun 19, 2009If you look at the first line of your error message, notice it says that on line 9 a "then" is expected.Posted in: Unit Frames
Tack "then" to the end of that line, and it should be okay.
elseif fact=="Horde" then
I looked more at that.
Make sure all the "elseif" lines end with "then".
Jun 19, 2009While looking through the API page for WoW at wowwiki.com, I noticed that there is a function UnitPower(unit,[type]) that seems to be identical to the function Power(unit,[type]) offered by Lua Text.Posted in: Unit Frames
Given the context of much of Shefki's admonitions ("zomg! redundant calls!"), I'm clearly missing something.
(BTW, pqee, I was looking over there to find the pet owner name function, and couldn't see one.)
Jun 18, 2009Posted in: Unit Frames
I never copy anything exactly. :) I try to learn stuff.
In my defense, I wasn't trying to use "nil" as the rank of the spell, but rather as the spell name. I didn't realize that the second argument was EITHER an index OR a spell name.
I blame xor.
(Thank you, btw. :)
Jun 17, 2009sfan27,Posted in: Unit Frames
part of what lua text is trying to get people to do is avoid making multiple calls to the same function for the same piece of information.
You could edit your "health: (Current health | %health)" code to read
local s = Status(unit) local cr,cg,cb = ClassColor(unit) local currenthealth, maxhealth = HP(unit), MaxHP(unit) if s then return s end return "|cff%02x%02x%02x%s || %s%%|r",r,g,b,currenthealth,Percent(currenthealth,maxhealth)which would save a function call.
Without the change, what you have is basically identical to how it would have been done in DogTags.
Granted, saving one function call isn't a lot, but if you're in a 25-man, that's 25 calls saved.
However, it's a good habit to be in, for when you start doing more elaborate calls.
(Oh, you also forgot a comma. I'm sure it was a transcription error on your part, but I wouldn't want someone else to cut-and-paste your stuff and then QQ about it not working.)
Jun 17, 2009Posted in: Unit Frames
Just change the tests. Sorry. I'll update my previous post to make it correct. I didn't bother to pay attention to that or test it in game. Trying to get through these forum posts quickly.
Okay... I've messed with it in a group, and Abolish detection seems lovely.
Debuff detection fails. Everyone (PCs; not mobs or NPCs) always has a Magic debuff. No matter what.
No one ever gets any other kind of debuff.
The only thing I can think of is that perhaps the "HARMFUL" filter is acting badly?
I've tried cutting out the Abolish detection and some other things (which didn't work). I'm not sure what else to change.
I cut out a few of the comments, and some spaces (to make things tidier).
local i = 1 local found = false local pois,dise,curs,magi,abop,abod = "","","","","","" while true do local n,_,_,_,dtype = UnitAura(unit,i,nil,"HARMFUL") if not n then break elseif dtype == "Poison" then pois = "|cff5dfc0aP|r" found = true elseif dtype == "Disease" then dise = "|cff7b3f00D|r" found = true elseif dtype == "Magic" then magi = "|cffccffffM|r" found = true elseif dtype == "Curse" then curs = "|cffff00ffC|r" found = true end i=i+1 end local n = UnitAura(unit,"Abolish Poison",nil,"HELPFUL") if n then abop = "|cffff0033AP|r" found = true end n = UnitAura(unit,"Abolish Disease",nil,"HELPFUL") if n then abod = "|cffff0033AD|r" found = true end if found then return "%s%s%s%s%s%s",pois,abop,dise,abod,magi,curs end
Jun 17, 2009Posted in: Unit Frames
<snip elegant fixing of my mistakes>
Now... what's it going to take to harangue you guys into doing something like this for Cowtip. :)
Also, talk was made about doing a dedicated "Lua Texts" sampler thread or page. Is there one around I haven't been able to find?
Jun 17, 2009Dogtags version: really simplePosted in: Unit Frames
[(HasDebuffType("Poison") ? "P":Green) (HasAura("Abolish Poison") ? "AP":Red) (HasDebuffType("Curse") ? "C":Fuchsia) (HasDebuffType("Disease") ? "D":Yellow) (HasAura("Abolish Disease") ? "AD":Red) (HasDebuffType("Magic") ? "M":Blue)]my attempt at luatext to do the same thing: epic fail
(Note, most of my lua coding is fumbling; I suck.)
if event == "UNIT_AURA" then local i = 1 local found = false local pois,dise,curs,magi,abop, abod = "","","","","","" while true do local n,_,_,_,dtype = UnitAura(unit,i,"HARMFUL") --"bright red" FF0033 if not n then break elseif dtype == "POISON" then pois = "|cff5DFC0A P|r" found = true --"green LED" elseif dtype == "DISEASE" then dise = "|cff7B3F00 D|r" found = true --"cinnamon" elseif dtype == "MAGIC" then magi = "|cffCCFFFF M|r" found = true --"aqua" elseif dtype == "CURSE" then curs = "|cffFF00FF C|r" found = true --"fuschia" end i=i+1 end local _,_,_,_,_,_,exp = UnitAura(unit,"Abolish Poison",nil,"HELPFUL") if exp ~= 0 then abop = "|cffFF0033 AP|r" found = true end local _,_,_,_,_,_,exp = UnitAura(unit,"Abolish Disease",nil,"HELPFUL") if exp ~= 0 then abop = "|cffFF0033 AD|r" found = true end if found then return "%s%s%s%s%s%s",pois,abop,dise,abod,magi,curs endI tried putting together stuff I found in posts 812, 875 and 876 (so, yes, I noticed 874.)
That's what I've got after a day of attempts.
I'd really like to get this down, as it's the last of my dogtags I have to convert. I had to enable Dogtags in PB4 last night *just* for this one tag. :) (Also, I'm apparently unable to find where to turn on border coloring based on debuffs.)
Jan 8, 2009_ForgeUser1187967 posted a message on Possible to chain actions off of iterated keypresses?That it's not definable in combat is fairly reasonable (and expected).Posted in: Addon Ideas
Why would it be complicated to code?
Jan 8, 2009_ForgeUser1187967 posted a message on Possible to chain actions off of iterated keypresses?I've an idea for a healer assistant addon, but i'm not sure if it's possible to do any more. (I stopped coding stuff pre-BC.)Posted in: Addon Ideas
The basic idea is that the same set of keys would function as both spell selection and then targetting.
For example, Spells1..5 are mapped to keys x1..x5, a subsequent press would target party member 1..5.
So like if I wanted to cast Heal1 on Party3 I could hit `x1' followed by `x3'. But then if I wanted to cast Heal3 on Party1 I could hit `x3' followed by `x1'.
Yes, I know I can just hit  and then [F3], and then  then [F1], but that's not the point.
I'm also aware that this would be untenable for raids larger than 10 or any kind of pet love.
- To post a comment, please login or register a new account.