Alright, so my next workshop is about producing better sounds in my game. So I was discovering the Sound Editor and reading through the Help file when several problems hit me. I'm going to expose those point per point.
1- Undocumented sound parameters
For starters, there are a bunch of undocumented parameters in the help file for modifying the Sound component directly from a ZExpression:
Envelope 1: Env0Active, Env0AttackTime, Env0DecayTime, Env0SustainLevel, Env0ReleaseTime
Envelope 2: Env1Active, Env1AttackTime, Env1DecayTime, Env1SustainLevel, Env1ReleaseTime
LFO 1: Lfo0Active, Lfo0Style, Lfo0IsBipolar, Lfo0Speed
LFO 2: Lfo1Active, Lfo1Style, Lfo1IsBipolar, Lfo1Speed
Modulation matrix 1: Mod0Active, Mod0Source, Mod0Destination, Mod0Amount
Modulation matrix 2: Mod1Active, Mod1Source, Mod1Destination, Mod1Amount
Modulation matrix 3: Mod2Active, Mod2Source, Mod2Destination, Mod2Amount
Modulation matrix 4: Mod3Active, Mod3Source, Mod3Destination, Mod3Amount
Those handy parameters merit a little place in the Help documentation
2- Consistency of parameter's names regarding numbers
The parameters that concern the Oscillator n°1 are named: Osc1Waveform, Osc1NoteModifier and Osc1PW
Same goes for Oscillator n°2: Osc2Waveform, Osc2NoteModifier and Osc2PW
But then there's the Modulation matrix, LFOs and Envelopes where the number in their names don't match the parameter name.
As an example, "Modulation matrix 1 activation" is named Mod0Active, not Mod1Active.
Ok, this isn't a big issue. But then, when you chose the Destination of the Modulation Matrix, the same thing is called Mod1Amount, not Mod0Amount. There's a little consistency issue here. The only other component that has numbers in its parameters names is the DefineCollision. And they are named Cat1 and Cat2, not Cat0 and Cat1.
3- About Modulation matrix Destination
In the list of selectable options for the Destination, there are a bunch of new names:
FilterCutoff, FilterQ, NoteNr, Lfo1Speed, Lfo2Speed, Mod1Amount, Mod2Amount, Mod3Amount, Mod4Amount, Osc1NoteMod, Osc2NoteMod, Volume, Pan, Osc2Vol, Osc1PW
They are not the full display names, nor the parameter names, but shorten names to fit inside the selector box. It's understandable, but also a bit confusing. And I still haven't found what Osc1PW stands for...
Again, I know that the names were shortened to fit inside the boxes, but I believe that could be better with consistent names.
4- Hard to find parameters
Why everything concerning the Modulation matrix, LFOs and Envelopes are only displayed in the Sound Editor detachable window? Why aren't they listed in the Sound properties, in the left column, like the other properties?
I had to discover the undocumented parameters listed above in order to realize that this detachable windows is really the parameters of the selected sound. But that took me a while because when I change something in that window, let's say the volume, then the parameter isn't modified in the Sound properties in the left column. I have to select another component and then select my sound again in order to see the change being taken into account.
I think all the Sound properties should be listed in the left column, like any other Components.
5- Show/hide properties as they are enabled or disabled
Adding all those properties to the left column will make it longer, and this isn't related directly to the Sound component, but could something like this be possible?
- unravel_options.gif (44.93 KiB) Viewed 8339 times
6- Oscillator 2 wave form
In the Help doc, it is said that we can choose between Square, Saw and Noise, but there are only Square and Saw.
By the way, why only those two, and not the same choices as oscillator 1?
7- About Envelopes documentation
Here's what the doc says:
Each sound can have a number of ADSR envelopes. For every envelope the following values can be set:
•Active - Set if this envelope is active.
•Attack time (A) - The time taken for initial run-up of level from zero to peak, beginning when the sound is being played.
•Decay time (D) - The time taken for the subsequent run down from the attack level to the designated sustain level.
•Sustain level (S) - The level during the main sequence of the sound's duration.
•Release time (R) - The time taken for the level to decay from the sustain level to zero.
What do you mean by time? Is it in seconds? Or is it relative to the length of the sound, so, some kind of % of the sound duration?
By the way, I just realized that there's a Help button right under Save as raw-file, that goes to
http://www.zgameeditor.org/index.php/ComponentRef.Sound which isn't consistent with the Help Documentation:
Each sound can have a number of envelopes.
For every envelope the following values can be set:
Active - Set if this envelope is active.
AttackTime - The duration of time that this envelope goes from zero to one.
ReleaseTime - The duration of time that this envelope returns from one to zero, after the AttackTime is finished.
Maybe the help in the wiki could be generated from the Github Help documentation too? But that's another problem for another day.
I think I'll stop there for today. I'll talk about the role of the sound editor's detachable window later, because I have some ideas to simplify it a bit