Table of Contents

ugBASIC User Manual

ENVELOPE

SYNTAX

   ENVELOPE voice, attack, decay, release

PURPOSE

The ENVELOPE command is used to define the volume of a sound over time, or its envelope. In simpler terms, it allows you to create richer and more complex sound effects, by defining the initial phase in which the sound rapidly increases in volume, the phase in which the sound decreases in volume, the final phase in which the sound fades away until it disappears. The ENVELOPE command uses internal tone generators to create these effects.

This command simulates different musical instruments, such as pianos, drums, sound effects, and more. It creates more complex and dynamic melodies and harmonies, and it can be used to create sound effects for games, such as explosions, gunshots, or ambient sounds.

EXAMPLE

  ENVELOPE 1, 1, 8, 10

ABBREVIATION

 Env

AVAILABLE ON

ANY PROBLEM?

If you have encountered a problem using this command, if you think there is a bug or the explanation is unclear, please open an issue for this keyword on GitHub. Thank you!

POWERED BY