File.loadSound

From MiniScript Wiki
Revision as of 18:13, 1 August 2020 by JoeStrout (talk | contribs) (Created page with "The <c>file.loadSound</c> loads a sound file from disk, returning a Sound object. The file may be in either WAV or OGG format. == Example == <ms>snd = file.loadSoun...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

The file.loadSound loads a sound file from disk, returning a Sound object. The file may be in either WAV or OGG format.

Example

snd = file.loadSound("/sys/sounds/bonus.wav")
snd.play