Show raw api
{
"functions": [
{
"name": "traverse",
"desc": "loop through all descendants of the given instance and call the parse function for each child.\n\nyou can also provide an optional class name to filter by.",
"params": [
{
"name": "root",
"desc": "the roblox instance to loop through.",
"lua_type": "Instance"
},
{
"name": "parse_fn",
"desc": "the function to call for each child.",
"lua_type": "(child: Instance) -> ()"
},
{
"name": "class",
"desc": "the class to filter by.",
"lua_type": "string?"
}
],
"returns": [],
"function_type": "static",
"source": {
"line": 35,
"path": "src/shared/utils/misc.luau"
}
},
{
"name": "copy",
"desc": "copy all children of the given instance to the destination folder.\nchildren have to be ModuleScripts in order to be copied.",
"params": [
{
"name": "root",
"desc": "the roblox instance to loop through.",
"lua_type": "Instance"
},
{
"name": "destination",
"desc": "the folder to copy the children to.",
"lua_type": "Folder"
}
],
"returns": [],
"function_type": "static",
"deprecated": {
"version": "0.1.0",
"desc": "use `misc_utils.traverse` instead"
},
"source": {
"line": 62,
"path": "src/shared/utils/misc.luau"
}
},
{
"name": "get_table_size",
"desc": "get the size of an array or a dictionary.",
"params": [
{
"name": "tbl",
"desc": "the table to get the size of.",
"lua_type": "{ any } | { [string]: any }"
}
],
"returns": [
{
"desc": "the size of the table.",
"lua_type": "number"
}
],
"function_type": "static",
"source": {
"line": 81,
"path": "src/shared/utils/misc.luau"
}
},
{
"name": "collect",
"desc": "collect events from a signal.",
"params": [
{
"name": "event",
"desc": "the signal to collect events from.",
"lua_type": "RBXScriptSignal"
}
],
"returns": [
{
"desc": "the iterator function and the disconnect function.",
"lua_type": "(() -> (number, any), () -> ())"
}
],
"function_type": "static",
"source": {
"line": 100,
"path": "src/shared/utils/misc.luau"
}
},
{
"name": "throttle",
"desc": "throttle a certain event. this works identically to matter's useThrottle hook.",
"params": [
{
"name": "time_or_name",
"desc": "the identifier for the throttle system.",
"lua_type": "number | any"
},
{
"name": "time",
"desc": "the time to wait before allowing the event to fire again.",
"lua_type": "number?"
}
],
"returns": [
{
"desc": "whether or not the event can continue.",
"lua_type": "boolean"
}
],
"function_type": "static",
"source": {
"line": 144,
"path": "src/shared/utils/misc.luau"
}
},
{
"name": "create_uuid",
"desc": "create a random uuid in a category.\n\nthe uuid is 14 characters long, and consists of both uppercase and lowercase letters, and numbers from 0-9.",
"params": [
{
"name": "uuid_type",
"desc": "the type of uuid to create.",
"lua_type": "uuid_type"
}
],
"returns": [
{
"desc": "the created uuid.",
"lua_type": "string"
}
],
"function_type": "static",
"source": {
"line": 198,
"path": "src/shared/utils/misc.luau"
}
}
],
"properties": [],
"types": [
{
"name": "uuid_type",
"desc": "a type of uuid. represents a category of uuids.",
"lua_type": "\"object\"",
"source": {
"line": 18,
"path": "src/shared/utils/misc.luau"
}
}
],
"name": "misc_utils",
"desc": "this module contains *miscellaneous utils* that *all* scripts can access and use.",
"tags": [
"utility"
],
"source": {
"line": 10,
"path": "src/shared/utils/misc.luau"
}
}