AthenaClient.systems.sound ​
Functions ​
frontend ​
Usage
AthenaClient.systems.sound.frontend(audioName, ref): void
Play a sound in the frontend.
https://altv.stuyk.com/docs/articles/tables/frontend-sounds.html
Parameters ​
| Name | Type | Description |
|---|---|---|
audioName | string | The name of the audio file to play. |
ref | string | The name of the sound you want to play. |
Returns ​
void
None
Defined in ​
handlePlayAudioPositional ​
Usage
AthenaClient.systems.sound.handlePlayAudioPositional(pos, soundName, soundInstantID?): void
Handle play audio positional
Parameters ​
| Name | Type |
|---|---|
pos | Vector3 |
soundName | string |
soundInstantID? | string |
Returns ​
void
Defined in ​
play2d ​
Usage
AthenaClient.systems.sound.play2d(soundName, volume?, soundInstantID?): void
Play a 2D sound.
Parameters ​
| Name | Type | Default value | Description |
|---|---|---|---|
soundName | string | undefined | The name of the sound to play. |
volume | number | 0.35 | The volume of the sound. |
soundInstantID? | string | undefined | - |
Returns ​
void
None
Defined in ​
play3d ​
Usage
AthenaClient.systems.sound.play3d(entity, soundName, soundInstantID?): void
Really basic 3D audio. Does not update after first play. Simply plays the audio based on your position.
Parameters ​
| Name | Type |
|---|---|
entity | Entity |
soundName | string |
soundInstantID? | string |
Returns ​
void
Defined in ​
stopAudio ​
Usage
AthenaClient.systems.sound.stopAudio(soundInstantID?): void
Stop audio.
Parameters ​
| Name | Type |
|---|---|
soundInstantID? | string |
Returns ​
void
None
V5 Docs