ScriptTypeRegistration

A reference to a type registration, in general think of this as a handle to a type.

type_name

Arguments:

ArgumentTypeDescription
sScriptTypeRegistrationThe type registration as returned by get_type_by_name

Returns:

ReturnDescription
StringThe type name
local name = MyType:type_name()

short_name

Arguments:

ArgumentTypeDescription
sScriptTypeRegistrationThe type registration as returned by get_type_by_name

Returns:

ReturnDescription
StringThe short name
local name = MyType:short_name()

is_resource

Arguments:

ArgumentTypeDescription
sScriptTypeRegistrationThe type registration as returned by get_type_by_name

Returns:

ReturnDescription
booltrue if the type is a resource, otherwise false
if MyType:is_resource() then
    print("MyType is a resource")
end

is_component

Arguments:

ArgumentTypeDescription
sScriptTypeRegistrationThe type registration as returned by get_type_by_name

Returns:

ReturnDescription
booltrue if the type is a component, otherwise false
if MyType:is_component() then
    print("MyType is a component")
end