GSC reference › Built-in
IsPlayingLoopSound()
Built-in (engine)
Client
Returns true if the entity is playing a loop sound
Signature
IsPlayingLoopSound([alias])
Parameters
| Name | Required? | Details |
|---|---|---|
| alias | Optional | specific alias to check for |
Example (from Treyarch's docs)
car IsPlayingLoopSound()
Real uses in BO3's scripts
Called 4 times in the decompiled scripts. A few, zombies first:
- scripts/mp/_helicopter_sounds.csc, line 849
if(surf_type == pre_surf_type && pre_trace_real_ent isplayingloopsound()) - scripts/mp/_helicopter_sounds.csc, line 920
if(surf_type == pre_surf_type && pre_trace_real_ent isplayingloopsound()) - scripts/cp/_helicopter_sounds.csc, line 834
if(surf_type == pre_surf_type && pre_trace_real_ent isplayingloopsound()) - scripts/cp/_helicopter_sounds.csc, line 905
if(surf_type == pre_surf_type && pre_trace_real_ent isplayingloopsound())
Related built-ins
- PlayLoopSound()Play a looping sound with an optional fadetime in seconds.
- StopLoopSound()Stops the looping sound with an optional fadetime.
- StopAllLoopSounds()Stops a loop sound
- SoundLoopEmitter()Play a sound loop at the position
- SoundStopLoopEmitter()Stop the sound loop emitter at the position
- SoundPlaying()Returns true if the sound given by sound id is playing
- PlaySound()Play the sound at the entity
- PlaySoundAtPosition()Play the sound alias from a position
- PlaySoundToPlayer()Play the sound alias as if coming from the entity, so that only one player can hear it
- PlaySoundWithNotify()Play the sound alias as if coming from the entity
- PlayLocalSound()Plays a sound locally
- StopSounds()Stop all sounds on an entity.
New to GSC?
Start with the basics, or paste a compile error to get the fix.
Built-in descriptions, parameters and examples come from Treyarch's BO3 mod tools docs. Usage links point at shiversoftdev/t7-source (decompiled BO3 scripts).