Showing results 1 to 25 of 33
Search took 0.01 seconds.
Search: Posts Made By: nailertn
Forum: oUF (Otravi Unit Frames) 10-17-12, 09:35 AM
Replies: 3
Views: 2,927
Posted By nailertn
What I don't really understand is oUF's event...

What I don't really understand is oUF's event dispatcher already does what RegisterUnitEvent is supposed to. Yet you see a lot of 'if unit ~= self.unit' everywhere in layouts and even in oUF's own...
Forum: Lua/XML Help 09-24-12, 06:58 AM
Replies: 2
Views: 1,511
Posted By nailertn
Events aren't specific like that. You just...

Events aren't specific like that. You just register for a generic UNIT_INVENTORY_CHANGED and then do a refined check to see if it was what you were looking for. Usually additional arguments sent by...
Forum: oUF (Otravi Unit Frames) 09-23-12, 03:19 PM
Replies: 0
Views: 1,633
Posted By nailertn
handling multiple raid layouts

I am wondering if there is a general consensus on what's the best practice for handling multiple raid layouts? I am swapping between layout 25 and layout 40 depending on the presence of raid26, which...
Forum: oUF (Otravi Unit Frames) 09-22-12, 02:48 PM
Replies: 7
Views: 3,115
Posted By nailertn
Do those changes include RegisterUnitEvent or do...

Do those changes include RegisterUnitEvent or do you intend to keep the event dispatcher as is for now?
Forum: UI Screenshots, Feedback and Design Discussion 09-16-12, 12:41 PM
Replies: 17
Views: 9,234
Posted By nailertn
The default color is white that's why commenting...

The default color is white that's why commenting does not work. And color values should be between 0-1, use 20/255 instead of 20.
Forum: Lua/XML Help 09-16-12, 03:36 AM
Replies: 15
Views: 3,513
Posted By nailertn
Parent / child relationship does not control...

Parent / child relationship does not control placement, anchoring does. If you anchor frame 1 to frame 2, then moving frame 2 will move frame 1 too. Moving frame 1 does nothing to frame 2. You can't...
Forum: AddOn Help/Support 09-16-12, 01:40 AM
Replies: 0
Views: 1,629
Posted By nailertn
oBindings state evaluation problem

I have modified oBindings (https://github.com/haste/oBindings) to accomodate extra keys on my keyboard and I am noticing some odd behaviour with macro condition evaluation. For example both...
Forum: oUF (Otravi Unit Frames) 09-12-12, 11:44 PM
Replies: 15
Views: 3,679
Posted By nailertn
After my second post the servers went live and I...

After my second post the servers went live and I have tested everything since then with the version that's available right here on Wowinterface. If you don't get the expected results some other...
Forum: oUF (Otravi Unit Frames) 09-12-12, 06:17 PM
Replies: 15
Views: 3,679
Posted By nailertn
I know how daunting it is, a few years ago I was...

I know how daunting it is, a few years ago I was exactly where you are now: staring at an oUF layout with zero coding knowledge.

local name = lib.gen_fontstring(f.Health, cfg.font, cfg.fontsize,...
Forum: oUF (Otravi Unit Frames) 09-12-12, 03:48 PM
Replies: 15
Views: 3,679
Posted By nailertn
What do you mean messed up? I don't see anything...

What do you mean messed up? I don't see anything wrong on that picture. If you mean truncated, that was precisely what you asked for. The code I gave you allows you to set name width on a per frame...
Forum: oUF (Otravi Unit Frames) 09-12-12, 03:38 AM
Replies: 15
Views: 3,679
Posted By nailertn
And lastly here is the aura border code. Again,...

And lastly here is the aura border code. Again, make a backup of lib.lua first.

Delete these:


CreateBorder = function(f,x)
h = CreateFrame("Frame", nil,...
Forum: oUF (Otravi Unit Frames) 09-12-12, 02:19 AM
Replies: 15
Views: 3,679
Posted By nailertn
Thumbs up One thing to note about pet frame colour is that...

One thing to note about pet frame colour is that pets have their own class. Most of them are considered warriors or paladins IIRC. If you want it green, you should just set it directly in the...
Forum: oUF (Otravi Unit Frames) 09-12-12, 12:22 AM
Replies: 15
Views: 3,679
Posted By nailertn
playerClass shouldn't start with a capital p....

playerClass shouldn't start with a capital p. That condition always evaluates to false, the original code has that error too. Just stick it in the main function, not inside that condition. Also seems...
Forum: oUF (Otravi Unit Frames) 09-11-12, 11:59 PM
Replies: 15
Views: 3,679
Posted By nailertn
This is the relevant part from...

This is the relevant part from ouf/health.lua

elseif(health.colorClass and UnitIsPlayer(unit)) or
(health.colorClassNPC and not UnitIsPlayer(unit)) or
(health.colorClassPet and...
Forum: Lua/XML Help 09-05-12, 09:44 PM
Replies: 3
Views: 2,457
Posted By nailertn
"Manipulating frame levels, frame stratas or draw...

"Manipulating frame levels, frame stratas or draw layers changes nothing." Even if it did, it still doesn't explain why a frame with leve 0 and strata "BACKGROUND" gets rendered on top of a frame...
Forum: Lua/XML Help 09-05-12, 04:10 PM
Replies: 3
Views: 2,457
Posted By nailertn
Scroll child draw order

Whenever I parent frames to a scroll child, it seems the rendering order of those frames are not governed by frame stratas / frame levels / draw layers but by the order in which they are added to the...
Forum: AddOn Help/Support 08-26-12, 03:45 AM
Replies: 7
Views: 2,856
Posted By nailertn
I looked into the code, it's not UI scale. For...

I looked into the code, it's not UI scale. For whatever reason there is a 1 pixel wide black texture created on the right side of every health bar. In lib.lua under lib.gen_hpbar:

s.reminder =...
Forum: Lua/XML Help 08-18-12, 04:13 PM
Replies: 13
Views: 4,716
Posted By nailertn
All of that is directly from WoW using...

All of that is directly from WoW using collectgarbage("count"). Both of us are talking about table size. Memory allocation is a convenient way to measure it.
Forum: Lua/XML Help 08-17-12, 09:53 PM
Replies: 13
Views: 4,716
Posted By nailertn
You can shrink tables by forcing a rehash: t =...

You can shrink tables by forcing a rehash:
t = {}
for i = 1,100 do
t[i] = true
end

-- t is 2084 bytes

for i = 1,100 do
t[i] = nil
Forum: Lua/XML Help 08-17-12, 08:19 PM
Replies: 11
Views: 3,082
Posted By nailertn
global_variable = 1 for i = 1, 1e8...

global_variable = 1

for i = 1, 1e8 do
global_variable = global_variable + 1
end

On my PC this runs in 4.98 seconds.

local local_variable = 1
Forum: oUF (Otravi Unit Frames) 03-29-10, 05:22 PM
Replies: 2
Views: 2,288
Posted By nailertn
In fact I just discovered __elements is no longer...

In fact I just discovered __elements is no longer iterated with ipairs but with next, and according to the Lua Reference Manual "the order in which the indices are enumerated is not specified, even...
Forum: oUF (Otravi Unit Frames) 03-29-10, 02:07 PM
Replies: 2
Views: 2,288
Posted By nailertn
element update order

I can't decide if I can rely on Health always updating before Power when traversing __elements. In oUF.lua elements is a hash table, both update functions are injected using a simple tinsert without...
Forum: oUF (Otravi Unit Frames) 03-29-10, 01:45 PM
Replies: 12
Views: 6,033
Posted By nailertn
It's a matter of how one prefers to organize...

It's a matter of how one prefers to organize really. I like setting up each element by going generic / unit specific, generic / unit specific. The former method focuses on unit, the latter on...
Forum: oUF (Otravi Unit Frames) 02-08-10, 08:14 AM
Replies: 5
Views: 2,373
Posted By nailertn
I have just briefly run through aura.lua so I may...

I have just briefly run through aura.lua so I may be off but:

PostUpdateAuraIcon sends the following arguments: object, icons, unit, icon, index, offset, filter, isDebuff. In your imbadatlua...
Forum: oUF (Otravi Unit Frames) 09-12-09, 07:42 AM
Replies: 2
Views: 2,528
Posted By nailertn
If the texture file you use has the border...

If the texture file you use has the border sections aligned and clustered correctly, it is actually pretty easy, something like the below code should do it.


local backdrop = {
bgFile =...
Showing results 1 to 25 of 33