findgc
Scans all game VMs for tables containing the given string key (or a list of keys), optionally matching a specific string value. Returns table proxies you can index directly. Returns nil, "no game lua state" when no state is found.
Syntax
findgc(key | keys: any) -> table
Parameters
| Parameter | Type | Description |
|---|---|---|
key | keys | any | The key | keys value used by the call. |
Returns
| Type | Description |
|---|---|
table | {table} |
Description
findgc is part of the GC & memory scanning library. GC helpers read the game's Luau heap from outside the process and can inspect or control the collector.
The call is read-only: it resolves the current value when invoked and does not change the underlying state.
The aliases findgc(key, value), findgc(nil, value) resolve to the same implementation.
Example
local hits = findgc("Leaderstats", "Cash")
for _, tbl in ipairs(hits) do
print(tbl)
end
Notes
- Aliases:
findgc(key, value),findgc(nil, value). - GC results depend on the live game heap and collector state.