Yuari
Documentation
Docs/Reflection

Reflection

Properties, hidden properties, callbacks and scriptability.

Lists reflected property names.

for name, value in pairs(getproperties(workspace)) do
    print(name, value)
end

Reads a non-scriptable property.

print(gethiddenproperty(workspace, "SomeHiddenProperty"))

Returns hidden properties.

local props = gethiddenproperties(workspace)
for name, value in pairs(props) do
    print(name, value)
end

Writes a non-scriptable property.

sethiddenproperty(workspace, "SomeHiddenProperty", true)

Returns the scriptable flag.

print(isscriptable(workspace, "Name"))

Sets the scriptable flag.

setscriptable(workspace, "Name", true)

Reads an instance callback.

print(getcallbackvalue(workspace, "ChildAdded"))

Writes an instance callback.

setcallbackvalue(workspace, "ChildAdded", function(child)
    print(child)
end)

Returns the hidden PhysicalConfigData value of an instance.

print(getpcd(workspace))

Reads a hidden BinaryString property, optionally Base64-encoded.

local value = getbspval(workspace.Baseplate, "PhysicalConfigData", true)
print(type(value))

Returns instances that reference the target through a property.

for _, instance in ipairs(getreferences(workspace.Baseplate)) do
    print(instance:GetFullName())
end