Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
GGSound allows for easy management of sound effects and global volume in your Corona SDK powered apps.
tree: 7d81038bd2

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
GGSound.lua
README.md

README.md

GGSound

GGSound allows for easy management of sound effects and global volume in your Corona SDK powered apps.

Basic Usage

Require the code
local GGSound = require( "GGSound" )
Create your sound library
local sound = GGSound:new{ 1, 2, 3 } -- Create the library passing in some channel numbers, these should be reserved by you.
Add some sounds
sound:add( "sound1.wav", "sound1" )
sound:add( audio.loadStream( "sound2.wav" ), "sound2" ) -- A preloaded sound.
Set the volume
sound:setVolume( 0.8 )
Play a sound
sound:play( "sound2" )
Disable all playback. Useful for debugging
sound.enabled = false
Remove a sound
sound:remove( "sound2" )
Remove all sounds
sound:removeAll()
Destroy the library
sound:destroy()
sound = nil

Update History

0.1

Initial release

Something went wrong with that request. Please try again.