03-21-12, 05:07 PM | #1 |
Questions Regarding oUF_Fail
Hey guys, thanks for the help a few weeks ago with oUF_Karma but now I'm trying out oUF_Fail (same author). I've been tinkering around with it for most of today trying to tweak it how I'd like it but, I've run into a few issues at the moment.
1) How do I go about removing all text from the Raid Frames? [Answered] 2) How do I go about removing all text from the Party Frames? [Answered] 3) How do I go about removing the latency from the end of all cast bars? [Answered] 4) Where do I adjust how many buffs/debuffs are in each row for the Target frame? [Answered] Please check post #8 for new questions. Thanks a lot for everyone's help so far (especially p3lim and Phanx) with all my oUF questions. Last edited by MiRai : 03-23-12 at 02:30 PM. |
|
03-21-12, 05:37 PM | #2 | ||||
I really wish people asking for help with a specific addon would provide a link to that addon's download page, so I didn't have to go hunt for it in order to try to help them... >_<
Code:
329. lib.gen_hpstrings(self)
Code:
367. lib.gen_hpstrings(self)
Code:
if f.mystyle == "player" then --latency (only for player unit) local z = s:CreateTexture(nil,"OVERLAY") z:SetTexture(cfg.statusbar_texture) z:SetVertexColor(1,0.1,0,.6) z:SetPoint("TOPRIGHT") z:SetPoint("BOTTOMRIGHT") s:SetFrameLevel(1) s.SafeZone = z -- custom latency display local l = lib.gen_fontstring(s, cfg.font, 10, "THINOUTLINE") l:SetPoint("CENTER", -2, 17) l:SetJustifyH("RIGHT") l:Hide() s.Lag = l f:RegisterEvent("UNIT_SPELLCAST_SENT", cast.OnCastSent) end
Code:
705. lib.createBuffs = function(f) Code:
738. lib.createDebuffs = function(f) Code:
717. b:SetWidth(f:GetWidth()) Code:
b:SetWidth(((b.size+b.spacing)*4)-b.spacing) |
|||||
03-21-12, 05:58 PM | #3 | |||
Commenting that out throws up this error: Code:
Message: Interface\AddOns\oUF_Fail\castbar.lua:102: attempt to index local 'sf' (a nil value) Time: 03/21/12 18:52:58 Count: 1 Stack: Interface\AddOns\oUF_Fail\castbar.lua:102: in function `PostCastStart' Interface\AddOns\oUF\elements\castbar.lua:61: in function `func' Interface\AddOns\oUF\events.lua:18: in function <Interface\AddOns\oUF\events.lua:16> (tail call): ? Locals: self = oUF_failCastbarplayer { 0 = <userdata> PostCastStop = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:120 CastingColor = <table> { } ChannelingColor = <table> { } Time = <unnamed> { } interrupt = true PostChannelStart = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:94 casting = true FailColor = <table> { } castid = 111 CompleteColor = <table> { } delay = 0 max = 1.5 Text = <unnamed> { } duration = 0 PostCastStart = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:94 Spark = <unnamed> { } __owner = oUF_failPlayer { } ForceUpdate = <function> defined @Interface\AddOns\oUF\elements\castbar.lua:378 Icon = <unnamed> { } PostCastInterrupted = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:135 PostChannelStop = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:129 PostCastFailed = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:135 OnUpdate = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:54 } unit = "player" name = "Red Proto-Drake" rank = nil text = 111 pcolor = <table> { 1 = 1 2 = 0.50196078431373 3 = 0.50196078431373 } interruptcb = <table> { 1 = 0.37254901960784 2 = 0.71372549019608 3 = 1 } sf = nil (*temporary) = 364466.943 (*temporary) = 364466.943 (*temporary) = 0.71372549019608 (*temporary) = 1 (*temporary) = <userdata> (*temporary) = "attempt to index local 'sf' (a nil value)" cast = <unnamed> { 0 = <userdata> setBarTicks = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:32 OnCastbarUpdate = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:54 PostCastStart = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:94 PostCastStop = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:120 PostChannelStop = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:129 PostCastFailed = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:135 OnCastSent = <function> defined @Interface\AddOns\oUF_Fail\castbar.lua:89 } channelingTicks = <table> { Mind Sear = 5 Soul Harvest = 4 Tranquility = 4 Hurricane = 10 Drain Soul = 5 Earthquake = 8 Mind Flay = 3 Penance = 2 Blizzard = 5 Arcane Missiles = 5 Evocation = 4 Drain Life = 5 Rain of Fire = 4 } Here's the castbar.lua code: lua Code:
I have yet to play with the width of the buffs but thanks for pointing me in the right direction. |
||||
03-21-12, 11:19 PM | #4 |
You need to comment out the parts of the code that try to manipulate the elements you already prevented from being created:
Line 69: Code:
self.Lag:SetFormattedText("%d ms", self.SafeZone.timeDiff * 1000) Code:
local sf = self.SafeZone sf.timeDiff = GetTime() - sf.sendTime sf.timeDiff = sf.timeDiff > self.max and self.max or sf.timeDiff sf:SetWidth(self:GetWidth() * sf.timeDiff / self.max) sf:Show() |
|
03-22-12, 07:46 AM | #5 |
Thanks for taking the time to look at this stuff.
*EDITED OUT BECAUSE ISSUE IS FIXED* Lines 90 and 91 also contain SafeZone text but, I'm not entirely sure whether I should be commenting out just 90 and 91 or 89 - 92. However, commenting out 89 - 92 seem to produce no change. Here is my updated castbar.lua w/o 89 - 92 commented out: lua Code:
EDIT: I'm sorry, I did mess up the above and all is currently well. Thank you once again. My question still stands about lines 89 - 92 -- Should something on them be commented out as I do not currently see a visual difference but, those lines contain SafeZone text and I'm just trying to cover any future cast bar issues. Last edited by MiRai : 03-22-12 at 08:37 AM. |
|
03-22-12, 03:43 PM | #6 |
You don't need to comment those lines out, because they check to see if the SafeZone sub-element exists before trying to manipulate it.
If you are obsessively concerned about shaving off a CPU cycle or two, you could comment out the calls to the whole OnCastSent function from the player frame, but realistically speaking you would not see any difference, so I wouldn't bother. |
|
03-22-12, 06:37 PM | #7 | |
|
||
03-23-12, 02:29 PM | #8 |
A few new questions that I have come up with. I've been playing with the code a lot today and have made some progress (yay me) but, some things are completely evading me. I've also updated the original post to reflect that there are new questions down here in this post.
Now, what I would like is for the Target's frame to look more like the Target of Target's frame (w/o class coloring the health percentage). This would mean removing the power and current/total health numbers. However, there are times that I would like to actually see the current health and power on mouse over (if possible). So, here are my questions: How do I go about adjusting the Target frame to only show the unit's current health instead of current/total (when injured)? How do I go about making the Target's current health text only show on mouse over? How do I go about hiding the Target's power text and only make it show on mouse over? Here are pastebin links to my Lua files since they are slightly different than the default: core.lua lib.lua tags.lua Also, here is a reference screenshot: Also, is it at all possible to make the battleground countdown-to-start timer look like the Mirror Castbar of oUF_Fail? Thanks again to everyone who has assisted me with my oUF questions so far. |
|
04-05-12, 04:35 AM | #9 |
I would also be interested in some info on how to style the battleground countdown-to-start timer, does someone have a hint?
|
|
04-05-12, 07:27 AM | #10 | |
I was actually laying low after the helpful people around here tore into that other guy. I did eventually figure how to manipulate the visibility of both the health and mana values per bar in the tags.lua file and my oUF_Fail is looking great.
lua Code:
I'm not even sure I'm going about this the correct why by calling it a mirror castbar. I believe /framestack is calling the frame "TimerTrackerTimer1" and "TimerTrackerTimer1StatusBar". Can I just make it look something like this? lua Code:
Don't laugh too hard I'm sure I'm murdering Lua. |
||
04-05-12, 05:54 PM | #11 |
Before asking for help/feedback on your code, your first step should always be to load it in-game, or at least run it through a Lua syntax checker, and attempting to fix the basic syntax errors. In this case, "if for ... end else ... end" is not valid Lua syntax.
If the TimerTrackerN bars have the same structure as the MirrorTimerN bars, then you can just add them to the existing list of bars the "for ... end" loop should iterate over (on line #3): Lua Code:
|
|
04-06-12, 05:04 PM | #12 | ||
The above code actually breaks the raid frames (odd?). I tested it a few times typing it out myself and directly copying and pasting it in. Also, I just saw /framestack report up to TimerTrackerTimer5 (only one bar total was actually visible) but, my main concern was on line 21. MirrorTimer uses the MirrorTimerStatusBar but TimerTrackerTimer uses TimerTrackerTimerStatusBar. I am assuming that some modification needs to be done to line 21 and I'll have to try it later tonight. I know you just said it helps to try your own code first but, I won't be able to for several hours and I just wanted to post this in case anyone who might know the answer shows up before I am able to test it out. =) Here is what I would test: Lua Code:
EDIT: The [highlight] won't accept the first set of spaces on the first line. |
|||
04-06-12, 09:47 PM | #13 |
The last post I made didn't work. I also tried to copy the entire chunk of code and rename the MirrorTimer parts to TimerTrackerTimer like so:
Lua Code:
And then add lib.gen_timertracker(self) right next to where lib.gen_mirrorcb(self) is in core.lua. That didn't work either and broke the target and targettarget frame of oUF_Fail. I recruited someone in an IRC channel who knows ~20% more Lua than I do (not much) and he couldn't figure it out either. He did point me towards a section of Skinner which skins the mirror castbar and battleground countdown timer like so: Lua Code:
Looking at that I'm really not sure where to go from there. |
|
04-06-12, 09:58 PM | #14 |
1. If anything is "breaking", then there is almost certainly a Lua error occuring. Install the addon BugSack to see the error(s), and then post it/them here.
2. The original code should be mis-anchoring the bar text (the line #21 issue you pointed out). Try this: Lua Code:
If it does not work as expected, see #1. |
|
04-06-12, 10:36 PM | #15 |
Sorry Phanx, you were right... my Lua errors were turned off in the game options. After turning them back on this is the error I get:
Code:
Message: Interface\AddOns\oUF_Fail\lib.lua:613: attempt to index local 'bar' (a nil value) Time: 04/06/12 23:18:25 Count: 1 Stack: Interface\AddOns\oUF_Fail\lib.lua:613: in function `gen_mirrorcb' Interface\AddOns\oUF_Fail\core.lua:162: in function <Interface\AddOns\oUF_Fail\core.lua:130> (tail call): ? Interface\AddOns\oUF\ouf.lua:271: in function <Interface\AddOns\oUF\ouf.lua:201> (tail call): ? Interface\AddOns\oUF\ouf.lua:560: in function `Spawn' Interface\AddOns\oUF_Fail\core.lua:510: in function `func' Interface\AddOns\oUF\factory.lua:17: in function <Interface\AddOns\oUF\factory.lua:13> (tail call): ? Locals: f = oUF_failTarget { 0 = <userdata> Highlight = <unnamed> { } Power = <unnamed> { } __tags = <table> { } PLAYER_ENTERING_WORLD = <function> defined @Interface\AddOns\oUF\ouf.lua:144 mystyle = "target" unit = "target" menu = <function> defined @Interface\AddOns\oUF_Fail\lib.lua:79 Castbar = oUF_failCastbartarget { } Health = <unnamed> { } RaidIcon = <unnamed> { } __elements = <table> { } style = "fail" } (for generator) = <function> defined =[C]:-1 (for state) = <table> { 1 = "MirrorTimer1" 2 = "MirrorTimer2" 3 = "MirrorTimer3" 4 = "TimerTrackerTimer1" 5 = "TimerTrackerTimer2" 6 = "TimerTrackerTimer3" 7 = "TimerTrackerTimer4" 8 = "TimerTrackerTimer5" } (for control) = 4 _ = 4 barName = "TimerTrackerTimer1" bar = nil (*temporary) = "TimerTrackerTimer1" (*temporary) = nil (*temporary) = MirrorTimer3StatusBar { 0 = <userdata> } (*temporary) = MirrorTimer3Text { 0 = <userdata> } (*temporary) = <unnamed> { 0 = <userdata> } (*temporary) = <function> defined @Interface\AddOns\oUF_Fail\lib.lua:60 (*temporary) = <unnamed> { 0 = <userdata> } (*temporary) = <function> defined =[C]:-1 (*temporary) = <unnamed> { 0 = <userdata> } (*temporary) = 0 (*temporary) = "attempt to index local 'bar' (a nil value)" cfg = <unnamed> { 0 = <userdata> TargetX = 0 showTargetBuffs = true showLFDIcons = true PlayerRelativePoint = "CENTER" TotX = 10 FocusX = -64 TargetRelativePoint = "CENTER" ShowIncHeals = true PartyX = -242 showRunebar = true PlayerX = -238 showpet = true buffsOnlyShowPlayer = false RCheckIcon = true ShowParty = true party_leader_icon = true font = "Interface\AddOns\oUF_Fail\media\Neuropol.ttf" PlayerY = -200 healthbarfontsize = 36 smallfont = "Interface\AddOns\oUF_Fail\media\Emblem.ttf" showShardbar = true showEclipsebar = true TotY = 6 ShowPlayerName = false FocusY = 390 showtot = true showAuraWatch = true scale = 1 highlight_texture = "Interface\AddOns\oUF_Fail\media\raidbg" backdrop_texture = "Interface\AddOns\oUF_Fail\media\backdrop" enableDebuffHighlight = true debuffhighlight_texture = "Interface\AddOns\oUF_Fail\media\debuff_highlight" statusbar_texture = "Interface\AddOns\oUF_Fail\media\healthbar" showfocustarget = true FocusRelativePoint = "TOPRIGHT" ShowRaid = true Castbars = true showVengeance = true TargetY = -152 TotRelativePoint = "TOPRIGHT" showTotemBar = true spark = "Interface\AddOns\oUF_Fail\media\spark" showHolybar = true RaidX = -200 backdrop_edge_texture = "Interface\AddOns\oUF_Fail\media\backdrop_edge" raidScale = 1 showPlayerAuras = false showRaidDebuffs = true debuffsOnlyShowPlayer = false powerbar_texture = "Interface\AddOns\oUF_Fail\media\powerbar" debuffBorder = "Interface\AddOns\oUF_Fail\media\iconborder" showfocus = true PartyY = -50 RaidY = -520 showTargetDebuffs = true } lib = <unnamed> { 0 = <userdata> gen_totemback = <function> defined @Interface\AddOns\oUF_Fail\lib.lua:72 ReadyCheck = <function> defined @Interface\AddOns\oUF_Fail\lib.lua:1038 createBuffs = <function> defined @Interface\AddOns\oUF_Fail\lib.lua:771 CreateThreatBorder = <function> defined @Interface\AddOns\oUF_Fail\lib.lua:410 addQuestIcon = <function> defined @Interface\AddOns\oUF_Fail\lib.lua:345 RogueComboPoints = <function> defined @Interface\AddOns\oUF_Fail\lib.lua:1145 UpdateThreat = <function> defined @Interface\AddOns\oUF_Fail\ Line 613 in my lib.lua file is line 13 in your chunk of code. If Bugsack prints out Lua errors with better information than the default UI I can get it for you tomorrow after I wake up but, I'm off for the night (it's way past my normal bedtime). Thank you for all the help you've given me so far. |
|
04-07-12, 12:17 AM | #16 |
I'm assuming you are talking about my most recent code and that you omitted the comment on line #1, so your line #13 is my line #14, in which case that error is occuring because no frame named "TimerTrackerTimer1" exists at the time the code is running.
Double-check the frame name. If it is not actually "TimerTrackerTimerN" then simply correcting the names in the list should resolve the issue. If the name is correct, then it must not be created yet at login, so you would need to either (a) more extensively modify the layout to detect when the timer bars are created, and skin them at that time, or (b) figure out which Blizzard_* addon creates the timer bars and force it to load at login. |
|
04-07-12, 10:52 AM | #17 | ||
I also jumped into a BG to test out the new code because the frame isn't present until you join one but, alas, the same error was given and again all oUF frames seem to be broken except the Player frame (target, targettarget, and raidframes all revert to Blizzard default). To make sure I'm actually providing the correct info I took a screenshot of two /framestacks in two different battlegrounds while hovering over the timer area. While the StatusBar portion isn't present in the bottom tooltip, it was there if I moved my mouse just slightly.
I'm going to head over to the Blizzard Macro & UI forum and throw this their way to see if someone knows something more about these infamous TimerTrackerTimer bars. I thank you for your time and effort Phanx and I feel bad that you're the only one assisting me with this (not that I'm entitled to any assistance at all ). |
|||
04-07-12, 12:56 PM | #18 |
Looking at the 4.3.3.15354 files from go-hero.net, I found that Timer.lua and Timer.xml both hold the term TimerTracker in them.
I've also made a post on the WoW Macro & UI forums to see what feedback I would get from there. http://us.battle.net/wow/en/forum/topic/4362521168 Timer.lua lua Code:
Timer.xml xml Code:
Last edited by MiRai : 04-07-12 at 12:59 PM. |
|
04-07-12, 02:08 PM | #19 |
Choonster from the WoW forums whipped up this code in an attempt for a fix:
Lua Code:
However, it is throwing up this error: Code:
Message: Interface\AddOns\oUF_Fail\lib.lua:694: unexpected symbol near ')' Time: 04/07/12 14:05:17 Count: 1 Stack: Locals: Line 694 is line 46 above and I tried changing ... to .. just to see what it wants and it tells me it expects '...' so, I don't know what unexpected symbol it's seeing? |
|
04-07-12, 09:14 PM | #20 |
The parenthesis at the end of line 46 should be at the end of line 52 instead.
|
|
WoWInterface » Featured Projects » oUF (Otravi Unit Frames) » Questions Regarding oUF_Fail |
«
Previous Thread
|
Next Thread
»
|
Display Modes |
Linear Mode |
Switch to Hybrid Mode |
Switch to Threaded Mode |
|
|