TONE
Plays a generated tone on a selected channel.
Syntax
`
Tone channel, frequency, duration
`
Description
TONE is the channel-first form of generated tone playback. It does the same basic job as SOUND, but it makes the channel choice part of the command every time.
Channels are useful in games and music because they let you separate different sound jobs. For example, channel 0 might be a melody, channel 1 might be effects, and channel 2 might be a warning beep. Other commands such as PAN and VOLUME can then target those channels.
The frequency controls pitch and the duration controls how long the tone lasts.
Example
`
tone 0, 440, 0.20
tone 1, 660, 0.20
sleep 300, 1
`
Notes

- Channels are zero-based.
- Use CHANNEL to set the default channel for generated commands that do not take a channel argument.

See also

- `Sound Library Reference`
- `Generated Sound Commands`