mirror of
https://github.com/OpenMW/openmw.git
synced 2025-06-20 16:41:33 +00:00
openmw.ambient
grammar, punctuation and wording tweaks
This commit is contained in:
parent
46cbee2f21
commit
1ef8d0570b
1 changed files with 22 additions and 22 deletions
|
@ -1,6 +1,6 @@
|
||||||
---
|
---
|
||||||
-- `openmw.ambient` controls background sounds, specific to given player (2D-sounds).
|
-- `openmw.ambient` controls background 2D sounds specific to a given player.
|
||||||
-- Can be used only by menu scripts and local scripts, that are attached to a player.
|
-- Can be used only by menu scripts and local scripts that are attached to a player.
|
||||||
-- @module ambient
|
-- @module ambient
|
||||||
-- @usage local ambient = require('openmw.ambient')
|
-- @usage local ambient = require('openmw.ambient')
|
||||||
|
|
||||||
|
@ -12,11 +12,11 @@
|
||||||
-- @param #string soundId ID of Sound record to play
|
-- @param #string soundId ID of Sound record to play
|
||||||
-- @param #table options An optional table with additional optional arguments. Can contain:
|
-- @param #table options An optional table with additional optional arguments. Can contain:
|
||||||
--
|
--
|
||||||
-- * `timeOffset` - a floating point number >= 0, to skip some time (in seconds) from beginning of sound file (default: 0);
|
-- * `timeOffset` - a floating point number >= 0, to skip some time (in seconds) from the beginning of the sound (default: 0);
|
||||||
-- * `volume` - a floating point number >= 0, to set a sound volume (default: 1);
|
-- * `volume` - a floating point number >= 0, to set the sound's volume (default: 1);
|
||||||
-- * `pitch` - a floating point number >= 0, to set a sound pitch (default: 1);
|
-- * `pitch` - a floating point number >= 0, to set the sound's pitch (default: 1);
|
||||||
-- * `scale` - a boolean, to set if sound pitch should be scaled by simulation time scaling (default: true);
|
-- * `scale` - a boolean, to set if the sound's pitch should be scaled by simulation time scaling (default: true);
|
||||||
-- * `loop` - a boolean, to set if sound should be repeated when it ends (default: false);
|
-- * `loop` - a boolean, to set if the sound should be repeated when it ends (default: false);
|
||||||
-- @usage local params = {
|
-- @usage local params = {
|
||||||
-- timeOffset=0.1
|
-- timeOffset=0.1
|
||||||
-- volume=0.3,
|
-- volume=0.3,
|
||||||
|
@ -29,14 +29,14 @@
|
||||||
---
|
---
|
||||||
-- Play a 2D sound file
|
-- Play a 2D sound file
|
||||||
-- @function [parent=#ambient] playSoundFile
|
-- @function [parent=#ambient] playSoundFile
|
||||||
-- @param #string fileName Path to sound file in VFS
|
-- @param #string fileName Path to a sound file in VFS
|
||||||
-- @param #table options An optional table with additional optional arguments. Can contain:
|
-- @param #table options An optional table with additional optional arguments. Can contain:
|
||||||
--
|
--
|
||||||
-- * `timeOffset` - a floating point number >= 0, to skip some time (in seconds) from beginning of sound file (default: 0);
|
-- * `timeOffset` - a floating point number >= 0, to skip some time (in seconds) from the beginning of the sound file (default: 0);
|
||||||
-- * `volume` - a floating point number >= 0, to set a sound volume (default: 1);
|
-- * `volume` - a floating point number >= 0, to set a the sound's volume (default: 1);
|
||||||
-- * `pitch` - a floating point number >= 0, to set a sound pitch (default: 1);
|
-- * `pitch` - a floating point number >= 0, to set a the sound's pitch (default: 1);
|
||||||
-- * `scale` - a boolean, to set if sound pitch should be scaled by simulation time scaling (default: true);
|
-- * `scale` - a boolean, to set if the sound's pitch should be scaled by simulation time scaling (default: true);
|
||||||
-- * `loop` - a boolean, to set if sound should be repeated when it ends (default: false);
|
-- * `loop` - a boolean, to set if the sound should be repeated when it ends (default: false);
|
||||||
-- @usage local params = {
|
-- @usage local params = {
|
||||||
-- timeOffset=0.1
|
-- timeOffset=0.1
|
||||||
-- volume=0.3,
|
-- volume=0.3,
|
||||||
|
@ -55,37 +55,37 @@
|
||||||
---
|
---
|
||||||
-- Stop a sound file
|
-- Stop a sound file
|
||||||
-- @function [parent=#ambient] stopSoundFile
|
-- @function [parent=#ambient] stopSoundFile
|
||||||
-- @param #string fileName Path to sound file in VFS
|
-- @param #string fileName Path to a sound file in VFS
|
||||||
-- @usage ambient.stopSoundFile("Sound\\test.mp3");
|
-- @usage ambient.stopSoundFile("Sound\\test.mp3");
|
||||||
|
|
||||||
---
|
---
|
||||||
-- Check if sound is playing
|
-- Check if a sound is playing
|
||||||
-- @function [parent=#ambient] isSoundPlaying
|
-- @function [parent=#ambient] isSoundPlaying
|
||||||
-- @param #string soundId ID of Sound record to check
|
-- @param #string soundId ID of Sound record to check
|
||||||
-- @return #boolean
|
-- @return #boolean
|
||||||
-- @usage local isPlaying = ambient.isSoundPlaying("shock bolt");
|
-- @usage local isPlaying = ambient.isSoundPlaying("shock bolt");
|
||||||
|
|
||||||
---
|
---
|
||||||
-- Check if sound file is playing
|
-- Check if a sound file is playing
|
||||||
-- @function [parent=#ambient] isSoundFilePlaying
|
-- @function [parent=#ambient] isSoundFilePlaying
|
||||||
-- @param #string fileName Path to sound file in VFS
|
-- @param #string fileName Path to a sound file in VFS
|
||||||
-- @return #boolean
|
-- @return #boolean
|
||||||
-- @usage local isPlaying = ambient.isSoundFilePlaying("Sound\\test.mp3");
|
-- @usage local isPlaying = ambient.isSoundFilePlaying("Sound\\test.mp3");
|
||||||
|
|
||||||
---
|
---
|
||||||
-- Play a sound file as a music track
|
-- Play a sound file as a music track
|
||||||
-- @function [parent=#ambient] streamMusic
|
-- @function [parent=#ambient] streamMusic
|
||||||
-- @param #string fileName Path to file in VFS
|
-- @param #string fileName Path to a file in VFS
|
||||||
-- @param #table options An optional table with additional optional arguments. Can contain:
|
-- @param #table options An optional table with additional optional arguments. Can contain:
|
||||||
--
|
--
|
||||||
-- * `fadeOut` - a floating point number >= 0, time (in seconds) to fade out current track before playing this one (default 1.0);
|
-- * `fadeOut` - a floating point number >= 0, time (in seconds) to fade out the current track before playing this one (default 1.0);
|
||||||
-- @usage local params = {
|
-- @usage local params = {
|
||||||
-- fadeOut=2.0
|
-- fadeOut=2.0
|
||||||
-- };
|
-- };
|
||||||
-- ambient.streamMusic("Music\\Test\\Test.mp3", params)
|
-- ambient.streamMusic("Music\\Test\\Test.mp3", params)
|
||||||
|
|
||||||
---
|
---
|
||||||
-- Stop to play current music
|
-- Stop the currently playing music
|
||||||
-- @function [parent=#ambient] stopMusic
|
-- @function [parent=#ambient] stopMusic
|
||||||
-- @usage ambient.stopMusic();
|
-- @usage ambient.stopMusic();
|
||||||
|
|
||||||
|
@ -98,7 +98,7 @@
|
||||||
---
|
---
|
||||||
-- Play an ambient voiceover.
|
-- Play an ambient voiceover.
|
||||||
-- @function [parent=#ambient] say
|
-- @function [parent=#ambient] say
|
||||||
-- @param #string fileName Path to sound file in VFS
|
-- @param #string fileName Path to a sound file in VFS
|
||||||
-- @param #string text Subtitle text (optional)
|
-- @param #string text Subtitle text (optional)
|
||||||
-- @usage -- play voiceover and print messagebox
|
-- @usage -- play voiceover and print messagebox
|
||||||
-- ambient.say("Sound\\Vo\\Misc\\voice.mp3", "Subtitle text")
|
-- ambient.say("Sound\\Vo\\Misc\\voice.mp3", "Subtitle text")
|
||||||
|
@ -108,7 +108,7 @@
|
||||||
---
|
---
|
||||||
-- Stop an ambient voiceover
|
-- Stop an ambient voiceover
|
||||||
-- @function [parent=#ambient] stopSay
|
-- @function [parent=#ambient] stopSay
|
||||||
-- @param #string fileName Path to sound file in VFS
|
-- @param #string fileName Path to a sound file in VFS
|
||||||
-- @usage ambient.stopSay();
|
-- @usage ambient.stopSay();
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
Loading…
Reference in a new issue