SetInstanceVolume - Sound
Revision as of 11:46, 3 December 2015 by imported>Plplecuyer
Member of: Sound Script
Modify the volume of a playing sound instance.
Syntax[edit | edit source]
Function SetInstanceVolume(int aiPlaybackInstance, float afVolume) native global
Parameters[edit | edit source]
- aiPlaybackInstance: The instance ID of the sound whose playback volume we wish to modify.
- afVolume: The desired volume of a playing sound instance. Values outside of 0.0 - 1.0 will be clamped.
Return Value[edit | edit source]
None.
Examples[edit | edit source]
int instanceID = mySFX.play(self) ; play mySFX sound from my self
Sound.SetInstanceVolume(instanceID, 0.5) ; play at half volume