# setVehicleSuspensionHeight (Shared)

> Raises or lowers a vehicle's suspension.

- **Platform**: MY Multiplayer (MYMP)
- **Kind**: Lua Function
- **Side**: Shared
- **Category**: Vehicles
- **URL**: https://wiki.mymp.gg/en/setVehicleSuspensionHeight

## Syntax

```lua
bool setVehicleSuspensionHeight(element vehicle, float height)
```

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `vehicle` | `element` | The vehicle. It can also be a parent element: every vehicle below it changes. |
| `height` | `float` | Height in metres, from -1 to 1. Negative lowers, positive raises, 0 goes back to normal. |

## Returns

`true` if the element given is a vehicle and it changed. With a parent element, the vehicles below it change even when the result is `false`.

It only applies to vehicles that ride on wheels. Lowering stops before the wheels reach the wheel arches. Called on the server, the change reaches every player.

## Example

```lua
addCommandHandler("rebaixar", function(player)
    local vehicle = getPedOccupiedVehicle(player)
    if vehicle then
        setVehicleSuspensionHeight(vehicle, -0.08)
    end
end)
```

### Note

A value outside -1 to 1 is an error.

## See also

- [getVehicleSuspensionHeight (Shared)](https://wiki.mymp.gg/en/getVehicleSuspensionHeight.md): Returns the suspension height setVehicleSuspensionHeight gave a vehicle.
- [setVehicleHydraulics (Shared)](https://wiki.mymp.gg/en/setVehicleHydraulics.md): Fits or removes a vehicle's hydraulics.
- [setVehicleWheelOffset (Shared)](https://wiki.mymp.gg/en/setVehicleWheelOffset.md): Moves a vehicle's wheels away from where the model places them.
