sounds
Vars | |
all_sounds | All valid sound files in the sound directory |
---|---|
channel_list | List of all channels as numbers |
channel_random_low | lower iteration position - Incremented and looped to get "random" sound channels for normal sounds. The channel at this index is returned when asking for a random channel. |
channel_reserve_high | higher reserve position - decremented and incremented to reserve sound channels, anything above this is reserved. The channel at this index is the highest unreserved channel. |
random_channels_min | Amount of channels to reserve for random usage rather than reservations being allowed to reserve all channels. Also a nice safeguard for when someone screws up. |
reserved_channels | Associative list of all reserved channels associated to their position. "[channel_number]" = index as number |
using_channels | Assoc list, "[channel]" = either the datum using it or TRUE for an unsafe-reserved (datumless reservation) channel |
using_channels_by_datum | Assoc list datum = list(channel1, channel2, ...) for what channels something reserved. |
Procs | |
available_channels_left | How many channels we have left. |
free_channel | Frees a channel and updates the datastructure. Private proc. |
free_datum_channels | Frees all the channels a datum is using. |
free_datumless_channels | Frees all datumless channels |
free_sound_channel | Removes a channel from using list. |
random_available_channel | Random available channel, returns number |
random_available_channel_text | Random available channel, returns text. |
reserve_channel | Reserves a channel and updates the datastructure. Private proc. |
reserve_sound_channel | Reserves a channel for a datum. Automatic cleanup only when the datum is deleted. Returns an integer for channel. |
reserve_sound_channel_datumless | NO AUTOMATIC CLEANUP - If you use this, you better manually free it later! Returns an integer for channel. |
Var Details
all_sounds
All valid sound files in the sound directory
channel_list
List of all channels as numbers
channel_random_low
lower iteration position - Incremented and looped to get "random" sound channels for normal sounds. The channel at this index is returned when asking for a random channel.
channel_reserve_high
higher reserve position - decremented and incremented to reserve sound channels, anything above this is reserved. The channel at this index is the highest unreserved channel.
random_channels_min
Amount of channels to reserve for random usage rather than reservations being allowed to reserve all channels. Also a nice safeguard for when someone screws up.
reserved_channels
Associative list of all reserved channels associated to their position. "[channel_number]" =
index as number
using_channels
Assoc list, "[channel]" =
either the datum using it or TRUE for an unsafe-reserved (datumless reservation) channel
using_channels_by_datum
Assoc list datum = list(channel1, channel2, ...) for what channels something reserved.
Proc Details
available_channels_left
How many channels we have left.
free_channel
Frees a channel and updates the datastructure. Private proc.
free_datum_channels
Frees all the channels a datum is using.
free_datumless_channels
Frees all datumless channels
free_sound_channel
Removes a channel from using list.
random_available_channel
Random available channel, returns number
random_available_channel_text
Random available channel, returns text.
reserve_channel
Reserves a channel and updates the datastructure. Private proc.
reserve_sound_channel
Reserves a channel for a datum. Automatic cleanup only when the datum is deleted. Returns an integer for channel.
reserve_sound_channel_datumless
NO AUTOMATIC CLEANUP - If you use this, you better manually free it later! Returns an integer for channel.