Syntax
getinstancesbyclass(className: string): tableAliases
getinstancesofclassArguments
| Name | Type | Description |
|---|---|---|
className | string | Roblox class name to match. |
Returns
| Name | Type | Description |
|---|---|---|
instances | table | Array table of matching instances. |
Description
Returns reachable instances whose class name matches the provided class.
Call it with 1 parameter(s): className. The argument table explains which values are required and which ones only refine the behavior.
It returns instances (table). Use the returns table to separate successful values from nil results and recoverable errors.
Example
Example call with placeholder values.
local result = getinstancesbyclass("example")
print(result)