# engineGetModels (Client)

> Lists the models this client knows, with where each comes from.

- **Platform**: MY Multiplayer (MYMP)
- **Kind**: Lua Function
- **Side**: Client
- **Category**: Models
- **URL**: https://wiki.mymp.gg/en/engineGetModels

## Syntax

```lua
table engineGetModels([string kind = nil])
```

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `kind` | `string` | Only models of this kind: `object`, `vehicle`, `ped` or `weapon`. Without it, every model. *(default: `nil`)* |

## Returns

A table keyed by model name. Each value has `origin` (`"engine"` or `"content"`), `owner` (the pack or resource that brought it), `kind`, `drawable` (who gives the drawable it draws) and, for a model made with `engineCreateModel` from a parent, `parent`. Raises an error if `kind` is unknown.

## Example

```lua
for name, info in pairs(engineGetModels("vehicle")) do
    if info.parent then
        print(name .. " is based on " .. info.parent)
    end
end
```

## See also

- [engineCreateModel (Client)](https://wiki.mymp.gg/en/engineCreateModel.md): Makes a new model under a name, on this client only. It is used by its name, like any other model.
- [engineGetModelTxds (Client)](https://wiki.mymp.gg/en/engineGetModelTxds.md): Lists the txds a model takes its textures from, in the order it searches them.
- [engineGetTxds (Client)](https://wiki.mymp.gg/en/engineGetTxds.md): Lists every texture dictionary this client knows, with where each one comes from.
