EmitGameSoundToAll Function

Wrapper to emit game sound to all clients.

Game sounds are found in a game's scripts/game_sound.txt or other files referenced from it

Note that if a game sound has a rndwave section, one of them will be returned at random.

bool EmitGameSoundToAll(const char[] gameSound, int entity, int flags, int speakerentity, const float origin[3], const float dir[3], bool updatePos, float soundtime)

Parameters

const char[] gameSound

Name of game sound.

int entity

Entity to emit from.

int flags

Sound flags.

int speakerentity

Unknown.

const float[3] origin

Sound origin.

const float[3] dir

Sound direction.

bool updatePos

Unknown (updates positions?)

float soundtime

Alternate time to play sound for.

Return Value

No description.

Errors

Invalid client index.