# getVehicleMaxPassengers (Server)

> Tells how many passengers fit in a vehicle, not counting the driver.

- **Platform**: MY Multiplayer (MYMP)
- **Kind**: Lua Function
- **Side**: Server
- **Category**: Vehicles
- **URL**: https://wiki.mymp.gg/en/getVehicleMaxPassengers-server
- **Counterpart**: Also exists on the client, with its own implementation: [getVehicleMaxPassengers (Client)](https://wiki.mymp.gg/en/getVehicleMaxPassengers-client.md)

## Syntax

```lua
int|false getVehicleMaxPassengers(vehicle|string vehicle)
```

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `vehicle` | `vehicle\|string` | The vehicle, or a vehicle model's name. |

## Returns

The number of passenger seats, or `false` if the model is unknown.

## Example

```lua
addCommandHandler("lugares", function(player, command, model)
    local seats = getVehicleMaxPassengers(model or "infernus")
    outputDebugString(tostring(seats))
end)
```

### Coming from MTA

Takes the model's name instead of its number.

## See also

- [getVehicleOccupants (Shared)](https://wiki.mymp.gg/en/getVehicleOccupants.md): Returns every ped and player inside a vehicle.
- [getVehicleOccupant (Shared)](https://wiki.mymp.gg/en/getVehicleOccupant.md): Returns the ped or player sitting in a seat of a vehicle.
- [warpPedIntoVehicle (Shared)](https://wiki.mymp.gg/en/warpPedIntoVehicle.md): Puts a ped or player straight into a vehicle seat, with no animation.
