isSoundPaused
Client-side
Server-side
Shared
Pair: setSoundPaused
This function is used to return the current pause state of the specified sound element.
If the element is a player, this function will use the players voice.
OOP Syntax Help! I don't understand this!
- Method: theSound:isPaused(...)
- Variable: .paused
Syntax
bool isSoundPaused ( sound/player theSound )
Required Arguments
- theSound: The sound element which pause state you want to return.
Returns
- bool: result
Returns true if the sound element is paused, false if unpaused or invalid arguments were passed.
Code Examples
client
This example will check and see if the sound is paused or not, and tell the player.
local theSound = playSound("music/song.mp3")
function checkSongPause() local pause = isSoundPaused(theSound) if(pause) then outputChatBox("The sound is paused!") else outputChatBox("The sound is not paused!") endendaddCommandHandler("checkpause", checkSongPause)
Changelog
See Also
Audio Functions
- getRadioChannel
- getRadioChannelName
- getSFXStatus
- getSoundBPM
- getSoundBufferLength
- getSoundEffectParameters
- getSoundFFTData
- getSoundEffects
- getSoundLength
- getSoundMaxDistance
- getSoundLevelData
- getSoundMetaTags
- getSoundMinDistance
- getSoundPan
- getSoundPosition
- getSoundSpeed
- getSoundWaveData
- getSoundVolume
- isSoundPaused
- isSoundPanningEnabled
- playSFX
- isSoundLooped
- getSoundProperties
- playSound
- playSFX3D
- setRadioChannel
- playSound3D
- setSoundEffectParameter
- setSoundEffectEnabled
- setSoundLooped
- setSoundMaxDistance
- setSoundMinDistance
- setSoundPan
- setSoundPaused
- setSoundPanningEnabled
- setSoundSpeed
- setSoundPosition
- setSoundProperties
- setSoundVolume
- stopSound