setSoundSpeed
Shared
Changes a sound's speed. The pitch changes with it. On the server, the change is sent to every client.
bool setSoundSpeed(sound sound, float speed)
Parameters
| Name | Type | Description |
|---|---|---|
| sound | sound | The sound element. On the client a dui element also works, for the browser's sound. |
| speed | float | The speed, where 1 is normal. It goes up to 16; 0 or less plays at normal speed. |
Returns
true if the sound was found, false otherwise.
Example
local music = playSound("sounds/track.mp3")
setSoundSpeed(music, 1.25)