setVolume.lua 455 B

12345678910111213141516171819
  1. return {
  2. summary = 'Set the volume of the Source.',
  3. description = 'Sets the current volume factor for the Source.',
  4. arguments = {
  5. {
  6. name = 'volume',
  7. type = 'number',
  8. description = 'The new volume.'
  9. },
  10. {
  11. name = 'units',
  12. type = 'VolumeUnit',
  13. default = [['linear']],
  14. description = 'The units of the value.'
  15. }
  16. },
  17. returns = {},
  18. notes = 'The volume will be clamped to a 0-1 range (0 dB).'
  19. }