getfunctionreferences
Finds what still refers to a function.
Syntax
getfunctionreferences(callback: function) -> {any}
Parameters
| Parameter | Type | Description |
|---|---|---|
callback | function | The function to look for. |
Returns
| Type | Description |
|---|---|
{any} | Tables that hold the function and Luau closures that capture it. |
Description
It follows the same rules as getobjectreferences and accepts only a function.
Example
local box = {handler = function() end}
for _, owner in getfunctionreferences(box.handler) do
print(owner == box)
end
These are Game executor contracts. Check build requirements and session lifetimes before using them.
