Audio
Allows the generation of chiptune audio.
- Version: v1.0.0
- Available since: LIKO-12 v0.7.0
- Last updated in: LIKO-12 v0.8.0
Methods:
Audio.generate
Generates a tune from wave, frequency, and amplitude
- Available since: Audio: v1.0.0, LIKO-12: v0.7.0
- Last updated in: Audio: v1.0.0, LIKO-12: v0.8.0
Audio.generate(wave, freq, amp)
Arguments:
- <wave> (number): The waveform id, it should be at least 0, but no more then 5.
- <freq> (number): The frequency of the tune.
- <amp> (number): The amplitude of the tune.
Audio.play
Plays a sound effect over a channel.
- Available since: Audio: v1.0.0, LIKO-12: v0.7.0
- Last updated in: Audio: v1.0.0, LIKO-12: v0.8.0
Audio.play(sfx, chn)
Arguments:
- <sfx> (table): The sound effect data.
- [chn] (number) (Default:
0
): A channel from 0 to 3.
Audio.stop
Stops the playing music.
- Available since: Audio: v1.0.0, LIKO-12: v0.7.0
- Last updated in: Audio: v1.0.0, LIKO-12: v0.8.0
Audio.stop()