The Sound object lets you play samples, which are short sounds like: jump, brake, select, hit, etc. Sounds are loaded entirely in the memory; therefore, this object is meant to be used only with samples. If you need to play longer things like music, consider using Music instead.
Creates a Sound object associated with a certain file.
path: string. The path of the sound - usually a file in the samples/ folder.
A Sound object.
playing: boolean, read-only.
true if the sound is playing.
The volume of the sound, a value between 0.0 and 1.0, inclusive (zero means silence).
Plays the sound.
Stops the sound.