function public(baseClass)
    local newClass = {}
    local newClassMt = {}

    newClassMt.__call = function(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11)
        local newInst = {arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11}
        setmetatable(newInst, {__index = newClass})
        if type(newInst.Create) == "function" then
            newInst:Create()
        end
        return newInst
    end

    if baseClass then
        newClassMt.__index = baseClass
    end

    setmetatable(newClass, newClassMt)

    function newClass:GetClass()
        return newClass
    end

    function newClass:GetBaseClass()
        return baseClass
    end

    function newClass:IsChildClassOf(class)
        local b = false
        local curClass = newClass

        while curClass and not b do
            if curClass == class then
                b = true
            else
                curClass = curClass:GetBaseClass()
            end
        end

        return b
    end

    return newClass
end