# C_Sound: World of Warcraft Forever API

Forever 1.60.1 (70959), Interface 16001, Lua 5.1, from Blizzard's own API documentation. Page: https://wowaddons.gg/forever-api/C_Sound

## Functions

### C_Sound.GetSoundScaledVolume

```lua
scaledVolume = C_Sound.GetSoundScaledVolume(soundHandle)
```

Arguments:
- `soundHandle`: number

Returns:
- `scaledVolume`: number

### C_Sound.IsPlaying

```lua
isPlaying = C_Sound.IsPlaying(soundHandle)
```

Arguments:
- `soundHandle`: number

Returns:
- `isPlaying`: bool

### C_Sound.PlayItemSound

```lua
C_Sound.PlayItemSound(soundType, itemLocation)
```

Arguments:
- `soundType`: ItemSoundType
- `itemLocation`: ItemLocation

### C_Sound.PlaySound

```lua
success, soundHandle = C_Sound.PlaySound(soundKitID, [uiSoundSubType], [forceNoDuplicates], [runFinishCallback], [overridePriority], [volumeOverride])
```

May return nothing.

Arguments:
- `soundKitID`: number
- `uiSoundSubType`: UISoundSubType, default "g_defaultSI3UISoundSubTypeForLua"
- `forceNoDuplicates`: bool, default false
- `runFinishCallback`: bool, default false
- `overridePriority`: number, may be nil
- `volumeOverride`: number, may be nil

Returns:
- `success`: bool
- `soundHandle`: SoundHandle

### C_Sound.PlaySoundWithOptions

```lua
success, soundHandle = C_Sound.PlaySoundWithOptions(params)
```

May return nothing.

Arguments:
- `params`: PlaySoundParams

Returns:
- `success`: bool
- `soundHandle`: SoundHandle

### C_Sound.PlayVocalErrorSound

```lua
C_Sound.PlayVocalErrorSound(vocalErrorSoundID)
```

Arguments:
- `vocalErrorSoundID`: Vocalerrorsounds

## Events

### SOUND_DEVICE_UPDATE

No payload.

### SOUNDKIT_FINISHED

Payload, after the event's name:
- `soundHandle`: number

## Tables

### PlaySoundParams (structure)

- `soundKitID`: number
- `uiSoundSubType`: UISoundSubType, default "g_defaultSI3UISoundSubTypeForLua"
- `forceNoDuplicates`: bool, default false
- `runFinishCallback`: bool, default false
- `overridePriority`: number, may be nil
- `volumeOverride`: number, may be nil

### PlaySoundResult (structure)

- `success`: bool
- `soundHandle`: SoundHandle

---
Make an addon with your AI: tell it "Read https://wowaddons.gg/agents.md, then make me a World of Warcraft Forever addon that …, try it with me in the game, and publish it."
