The battle continues...
I still haven't fully figured out the bewildering intricacies of SoundVolume and ChannelVolume. I would be grateful for any help with the following:
1) After pausing a sound with PauseChannel and then setting a new volume with ChannelVolume the sound continues playing at this new volume when resumed with ResumeChannel. However, the next time the sound plays the volume has reverted back to its previous volume setting. (Looped sounds work fine, as they do not stop.)
I assume the specified channel volume is supposed to remain in effect until the program ends?? Why are my channel volumes reverting?? Do I need to set the channel volume every time a sound is played??
2) I tried the same thing using SoundVolume but the new volume setting only takes effect AFTER the sound has finished playing. Am I right in thinking that ChannelVolume is only to be used WHILE a sound is playing?
3) In order to set the volume for all my sounds to a similar level I've used SoundVolume to set the base volume for each sound when my program first begins. When it comes time to change the overall volume level for my program though (by means of a slider bar), setting the new volume level is quite tricky as each sound has a different maximum volume. Is the best way to approach this problem just to use a sound editing program to set each sound's volume to a similar level in the first place? Doing this via code was my ambition.
I was told once that the value set with SoundVolume represented the maximum ChannelVolume for that sound (eg. SoundVolume = .3 -> ChannelVolume = 1 (.3 in actuality)). Tests seem to reveal that this is not true. This would have made things a lot easier.
4) When a program starts I assume the default sound/channel volume value for any sound is 1?
5) Is it possible to display a system alert dialog box like with RuntimeError but without it terminating the program? I just want a message to be displayed and then to return to the program upon clicking 'Ok'.
6) I've seen code examples with EndGraphics being executed before End. Is this necessary?
7) How do I go about setting and creating my own system file icons?
Phew! That's a lot off my mind. Any assistance with the above would be greatly appreciated.
I still haven't fully figured out the bewildering intricacies of SoundVolume and ChannelVolume. I would be grateful for any help with the following:
1) After pausing a sound with PauseChannel and then setting a new volume with ChannelVolume the sound continues playing at this new volume when resumed with ResumeChannel. However, the next time the sound plays the volume has reverted back to its previous volume setting. (Looped sounds work fine, as they do not stop.)
I assume the specified channel volume is supposed to remain in effect until the program ends?? Why are my channel volumes reverting?? Do I need to set the channel volume every time a sound is played??
2) I tried the same thing using SoundVolume but the new volume setting only takes effect AFTER the sound has finished playing. Am I right in thinking that ChannelVolume is only to be used WHILE a sound is playing?
3) In order to set the volume for all my sounds to a similar level I've used SoundVolume to set the base volume for each sound when my program first begins. When it comes time to change the overall volume level for my program though (by means of a slider bar), setting the new volume level is quite tricky as each sound has a different maximum volume. Is the best way to approach this problem just to use a sound editing program to set each sound's volume to a similar level in the first place? Doing this via code was my ambition.
I was told once that the value set with SoundVolume represented the maximum ChannelVolume for that sound (eg. SoundVolume = .3 -> ChannelVolume = 1 (.3 in actuality)). Tests seem to reveal that this is not true. This would have made things a lot easier.
4) When a program starts I assume the default sound/channel volume value for any sound is 1?
5) Is it possible to display a system alert dialog box like with RuntimeError but without it terminating the program? I just want a message to be displayed and then to return to the program upon clicking 'Ok'.
6) I've seen code examples with EndGraphics being executed before End. Is this necessary?
7) How do I go about setting and creating my own system file icons?
Phew! That's a lot off my mind. Any assistance with the above would be greatly appreciated.