function aUF:FindObjects() local table = {} for _,v in self do if type(v) == "table" then if AceOO.inherits(v, aUF.aUFunit) and v.name then if not table[v.type] then table[v.type] = {} end tinsert(table[v.type],v.name) end end end return table end function aUF:CallUnitMethods(class,func,arg) if aUF:FindObjects()[class] then for _,v in aUF:FindObjects()[class] do if func then self[v][func](self[v],arg) end end end end