View Single Post
01-24-10, 12:04 PM   #11
ArrchDK
A Fallenroot Satyr
 
ArrchDK's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2009
Posts: 25
Code:
/run
local function child(f) 
    if f:GetObjectType() == "Texture" then 
        print(f:GetTexture()) 
    else 
        local c = { f:GetChildren() } 
        for i = 1, getn(c) do 
            child(c[i])
        end
    end 
end
child(GetMouseFocus())
Untested, but it's a rough idea on how to do it. Basically just use recursion to walk the tree and find an object that is a texture. Remove the white space before testing, of course.
  Reply With Quote