Pop.Box/util.lua
Paul Liverman III 8bacbb2212 compiled!
2016-06-21 12:32:58 -07:00

20 lines
401 B
Lua

local inheritsFromElement
inheritsFromElement = function(object)
if object and object.__class then
local cls = object.__class
if cls.__name == "element" then
return true
end
while cls.__parent do
cls = cls.__parent
if cls.__name == "element" then
return true
end
end
end
return false
end
return {
inheritsFromElement = inheritsFromElement
}