Lookup RedM game-data asset (ped/weapon/object/door/vehicle)
asset_lookupResolve a RedM game-data asset (ped model, weapon, object, door, vehicle) by exact name, 32-bit hash, or partial-name search. O(1) structured lookup against pre-parsed discoveries tables — replaces the common workflow of grepping a_c_bear_01 in peds_list.lua, then cross-referencing RELATIONSHIP/README.md for its relationship group. Returns: type, name, normalized hash (0x + 8 uppercase hex), source file + line, plus type-specific metadata (peds get variants + relationship, weapons get group, doors get coords + model_hash, objects get category/subcategory). Catalog ~22,500 entries (mostly objects). Typical latency p50 ~15ms, p95 ~65ms.
NOT for:
Script natives like
SET_ENTITY_COORDS,GetPedHealth, or hashes fromCitizen.InvokeNative(0x...)— uselookup_native. Native hashes are 64-bit (0x06843DA7060A026B); asset hashes are 32-bit (0xBCFD0E7F). Different namespaces, never collide.Flag enums, settings, clipsets, scenario keys like
CPED_CONFIG_FLAGS,MP_Style_Casual,mech_loco_m@,MAGGIE_SEAT_CHAIR_DESK_WRITING. Those live as tokens in lua source but not in this catalog. Usegrep_docs.Behavior queries ("which animal is the bear", "weapons in the lemat family") — use
semantic_search.
Pass exactly ONE of name / hash / search. Optional type narrows to a category (useful when a fragment like "horse" hits both peds and vehicles). Note: type reflects the SOURCE FILE — the same asset name can exist under multiple types. e.g. mp006_p_mshine_int_door01x appears as type=object (1 row from object_list.lua) AND type=door (2 rows from doorhashes.lua, different door hashes for distinct in-world instances with coords). Pick type=door when you want lockable in-world doors with positions; type=object for the model itself.
Examples:
{name: "a_c_bear_01"}→ exact ped lookup, returns variants=11 + relationship=REL_WILD_ANIMAL_PREDATOR.{hash: "0xBCFD0E7F"}→ resolves to peda_c_bear_01(omit0xok).{search: "lemat", type: "weapon"}→ substring match →weapon_revolver_lemat.{search: "moonshine", type: "door"}→ exact substring misses (no door name contains "moonshine"), fuzzy trigram fallback fires →mp006_p_mshine_int_door01x. Fuzzy mainly fires whentypenarrows out the exact-substring matches; withouttype, common terms find substring hits first and never reach fuzzy.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hash | No | Asset hash (32-bit jenkins) in HEX format, case-insensitive, `0x` prefix optional. Examples: `0xBCFD0E7F`, `bcfd0e7f`. Use when you have a hash from decompiled code or another table and need the canonical name + metadata. Decimal-formatted hashes (e.g. `1946191463`) are NOT accepted — convert to hex first (`(1946191463).toString(16)`). | |
| name | No | Exact asset name, case-insensitive. Examples: `a_c_bear_01`, `weapon_pistol_volcanic`, `p_safe01`, `armysupplywagon`. Use when you know the precise name. | |
| type | No | Filter results to one category. Useful when a name fragment matches multiple types (e.g. `horse` hits peds + vehicles). | |
| limit | No | Max matches to return. Default 5, max 50. Only applies to `search` — exact `name`/`hash` always return 0 or 1. | |
| search | No | Substring fragment within asset name, case-insensitive. Examples: `lemat`, `norfolk`, `volcanic`. Use when you remember part of the name. Algorithm: exact substring (ILIKE) first; if zero hits, falls back to pg_trgm `strict_word_similarity` ≥0.4 — catches abbreviation gaps like `moonshine`↔`_mshine_` when narrowed by `type` (without `type`, common terms find substring matches first and fuzzy never fires). `matchType` in the response tells you which path hit: `search` = exact substring, `fuzzy` = trigram. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hint | Yes | ||
| assets | Yes | ||
| status | Yes | ||
| hashFormat | Yes | ||
| suggestions | Yes |