# Sandbox.Game.Music.Duck

```csharp
static System.IDisposable Duck(float amount = 0.8, float fade = 0.3)
```

Turn the music down while something more important plays over it - a trailer, a cutscene, a bit
of dialogue. `amount` is how much to duck by: 0.9 leaves the music at 10% of its
volume, 1 silences it completely. The track carries on playing underneath either way.

The music stays ducked until the returned handle is disposed, then fades back up - so hold onto
it for as long as you're playing over the top. If several things duck at once the strongest one
wins, so they don't need to know about each other.

### Parameters

- `amount` (`float`), default `0.8`: How much to turn the music down, 0 to 1.
- `fade` (`float`), default `0.3`: Seconds to fade down, and back up again afterwards.

### Returns

`System.IDisposable`

Declared in [Sandbox.Game.Music](/api/Sandbox.Game.Music).
Assembly: `Sandbox.Engine`.
