Type Function Library audio.* Return value Boolean Revision Release 2024.3703 Keywords audio, volume, min volume, set minimum, sound See also audio.getMinVolume() audio.setMaxVolume() audio.getMaxVolume() audio.getVolume() audio.setVolume()
Clamps the minimum volume to the set value. Any volumes that fall below the value will be played at the minimum volume level.
This function returns true
on success or false
if otherwise.
There is no max volume for the master volume.
audio.setMinVolume( volume, options )
Number. The new min volume level you want to apply. Valid numbers range from 0.0
to 1.0
, where 1.0
is the maximum value.
Table. Table that supports a single key, channel
, which is the channel number you want to set the minimum volume on. Valid channels are 1
to the maximum number of channels (currently 32). Specify 0
to apply the minimum volume to all channels.
audio.setMinVolume( 0.25, { channel=1 } )