setSoundSpeed
Client-side
Server-side
Shared
Pair: getSoundSpeed
This function can be used to change the playback speed of the specified sound element.
OOP Syntax Help! I don't understand this!
- Method: sound:setSpeed(...)
- Variable: .speed
Syntax
bool setSoundSpeed ( sound/player theSound, float speed )
Required Arguments
- theSound: The sound element which speed you want to modify.
- speed: A floating point number representing the desired sound playback speed.
Returns
- bool: result
Returns true if the sound element playback speed was successfully changed, false otherwise.
Code Examples
client
function soundFunc()local sound = playSound ( "/sounds/jizzy.mp3",true) -- Let's play a soundsetSoundSpeed ( sound, 1.2 ) -- And it will be a little bit faster !endaddCommandHandler("play",soundFunc)
See Also
Audio Functions
- getRadioChannel
- getRadioChannelName
- getSFXStatus
- getSoundEffectParameters
- getSoundBPM
- getSoundEffects
- getSoundFFTData
- getSoundBufferLength
- getSoundLength
- getSoundLevelData
- getSoundMetaTags
- getSoundMinDistance
- getSoundMaxDistance
- getSoundPan
- getSoundProperties
- getSoundSpeed
- getSoundVolume
- getSoundWaveData
- getSoundPosition
- isSoundPanningEnabled
- isSoundLooped
- isSoundPaused
- playSFX
- playSFX3D
- playSound3D
- playSound
- setSoundEffectEnabled
- setSoundEffectParameter
- setRadioChannel
- setSoundLooped
- setSoundMaxDistance
- setSoundMinDistance
- setSoundPan
- setSoundPanningEnabled
- setSoundSpeed
- setSoundVolume
- stopSound
- setSoundProperties
- setSoundPaused
- setSoundPosition