Difference between revisions of "Gksound"

From Vendetta Lua
Jump to: navigation, search
(New page: Functions ot control audio playback. Audio files read from disk must be in ogg vorbis format. == Functions == === GKPlaylist === '''Definition:'''<br> GKPlaylist(string playlist) -> nil ...)
 
(GKPlaySound)
Line 50: Line 50:
 
'''Returns:'''
 
'''Returns:'''
 
<br><br>
 
<br><br>
'''Example:'''
+
'''Example:'''<br>
 +
GKPlaySound("explosion", 0.5) -> nil
 +
play explosion sound effect at half volume
 
<br><br>
 
<br><br>
 
 
  
 
=== GKStopMusic ===
 
=== GKStopMusic ===

Revision as of 20:12, 19 July 2007

Functions ot control audio playback. Audio files read from disk must be in ogg vorbis format.

Functions

GKPlaylist

Definition:
GKPlaylist(string playlist) -> nil

Description:
Play playlist file as background music.

Arguments:
playlist filename playlist file

Returns:

Example:


GKPlayMusic

Definition:
GKPlayMusic(string audiofile) -> nil

Description:
Playback the provided file as background music in a loop

Arguments:
audiofile filename of an audiofile

Returns:

Example:


GKPlaySound

Definition:
GKPlaySound(string soundeffect, float volume) -> nil

Description:
Playback a soundeffect at the given volume

Arguments:
soundeffect name of a soundeffect
volume playback volume (0-1)

Returns:

Example:
GKPlaySound("explosion", 0.5) -> nil play explosion sound effect at half volume

GKStopMusic

Definition:
GKStopMusic() -> nil

Description:
Stop playing background music

Arguments:

Returns:

Example: