I am using this to play sounds to the client with direction and distance information.
It works perfectly for what I am doing but I can't seem to change the volume and I would like to understand the parms for this function better.
1) For the Volume trying different constants like these or numbers doesn't seem to make any difference in the volume.
SNDLEVEL_TRAIN
SNDLEVEL_HELICOPTER
SNDLEVEL_AIRCRAFT
I am using SND_NOFLAGS.
Do I need to change this to SND_CHANGEVOL
to have the SNDLEVEL_* parms have an effect?
2) I am using
SNDCHAN_AUTO
but these are all death sounds from players.
Is SNDCHAN_AUTO the best choice or should I be using something like this instead?
SNDCHAN_VOICE
3) Again ANOTHER parm that seems to be related to volume!
SNDVOL_NORMAL
This is defined as 1.0
Is THIS the parm to change to change the volume?
If not what is this parm used for and what are the allowed values?
Changing it form 1.0 to 2.0 causes NO sounds to be played.
PHP Code:
EmitSoundToClient(client,snd[cSnd],SOUND_FROM_WORLD, SNDCHAN_AUTO, SNDLEVEL_AIRCRAFT, SND_NOFLAGS, SNDVOL_NORMAL, SNDPITCH_NORMAL, -1, loc);