mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
@@ -160,7 +160,7 @@ do -- Sound File
|
||||
-- @param #string FileName The name of the sound file, e.g. "Hello World.ogg".
|
||||
-- @param #string Path The path of the directory, where the sound file is located. Default is "l10n/DEFAULT/" within the miz file.
|
||||
-- @param #number Duration Duration in seconds, how long it takes to play the sound file. Default is 3 seconds.
|
||||
-- @param #bolean UseSrs Set if SRS should be used to play this file. Default is false.
|
||||
-- @param #boolean UseSrs Set if SRS should be used to play this file. Default is false.
|
||||
-- @return #SOUNDFILE self
|
||||
function SOUNDFILE:New(FileName, Path, Duration, UseSrs)
|
||||
|
||||
@@ -249,6 +249,9 @@ do -- Sound File
|
||||
-- @param #string Duration Duration in seconds. Default 3 seconds.
|
||||
-- @return #SOUNDFILE self
|
||||
function SOUNDFILE:SetDuration(Duration)
|
||||
if Duration and type(Duration)=="string" then
|
||||
Duration=tonumber(Duration)
|
||||
end
|
||||
self.duration=Duration or 3
|
||||
return self
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user