Questions about making an audio OXP
Moderators: winston, another_commander
Questions about making an audio OXP
Hey there,
while my previous attempt to make an audio OXP resulted in letting other people do the work and then acting like a diva for not getting 1000+ instantly and therefore not finishing my own version, I'd like do it properly this time.
However, I'm lacking the answers for the questions "what's scriptable" and "how to script that". One of the main problems I had with making the Crew Sound Pack was that I couldn't get it done that the same event wouldn't be triggered before the sound file of the first even finished playing, which was a bit unfortunate. However, this seems to be possible somehow, at least the sound for scooping works properly in the BGS.
For example, sounds I'd like to make would be different engine sounds for different ships and different conditions. A Ferdy should be much quieter than a Python, and an Anaconda should sound more calm and majestic than an Adder (in my opinion, that is). Also, I'd like to include different engine sounds for damaged or unmaintained ships. Would that be scriptable?
Oh, and higher speed should result in a faster (more high-pitched) engine, but I think Oolite itself can't pitch, right?
Also, as far as I know, Oolite itself can't fade, is that right? iTunes can, but it only does if it's the next item on a playlist, so that wouldn't apply to Oolite starting another song (e.g. transition between condition green and condition red). Plus, it'd be a Mac-only feature.
while my previous attempt to make an audio OXP resulted in letting other people do the work and then acting like a diva for not getting 1000+ instantly and therefore not finishing my own version, I'd like do it properly this time.
However, I'm lacking the answers for the questions "what's scriptable" and "how to script that". One of the main problems I had with making the Crew Sound Pack was that I couldn't get it done that the same event wouldn't be triggered before the sound file of the first even finished playing, which was a bit unfortunate. However, this seems to be possible somehow, at least the sound for scooping works properly in the BGS.
For example, sounds I'd like to make would be different engine sounds for different ships and different conditions. A Ferdy should be much quieter than a Python, and an Anaconda should sound more calm and majestic than an Adder (in my opinion, that is). Also, I'd like to include different engine sounds for damaged or unmaintained ships. Would that be scriptable?
Oh, and higher speed should result in a faster (more high-pitched) engine, but I think Oolite itself can't pitch, right?
Also, as far as I know, Oolite itself can't fade, is that right? iTunes can, but it only does if it's the next item on a playlist, so that wouldn't apply to Oolite starting another song (e.g. transition between condition green and condition red). Plus, it'd be a Mac-only feature.
Re: Questions about making an audio OXP
With BGS it is already possible to use a different set of sounds by simply adding script_info keys in shipdata.plist.Corny wrote:For example, sounds I'd like to make would be different engine sounds for different ships and different conditions. A Ferdy should be much quieter than a Python, and an Anaconda should sound more calm and majestic than an Adder (in my opinion, that is).
Code: Select all
script_info = {"bgs_engine" = "myEngine.ogg"; "bgs_engineUp" = "myEngineUp.ogg"; "bgs_engineDown" = "myEngineDown.ogg";};
Yep - no pitch, no fades, no volume control. Switching sounds on the fly may result in a somewhat annoying gap. And without a smooth transition between sounds it won't work well.Corny wrote:Also, I'd like to include different engine sounds for damaged or unmaintained ships. Would that be scriptable? Oh, and higher speed should result in a faster (more high-pitched) engine, but I think Oolite itself can't pitch, right?
Also, as far as I know, Oolite itself can't fade, is that right? iTunes can, but it only does if it's the next item on a playlist, so that wouldn't apply to Oolite starting another song (e.g. transition between condition green and condition red). Plus, it'd be a Mac-only feature.
Re: Questions about making an audio OXP
Oh, nice! I didn't know that. That does work as a separate oxp, right? So I could make a ship engines-OXP with only the script_info for each ship in the .plist, and it plays nicely with the shipdata.plists of other OXPs?
Re: Questions about making an audio OXP
No. It's a bit more complicated, because script_info entries in shipdata.plist are not merged together, they are overriding each other.Corny wrote:Oh, nice! I didn't know that. That does work as a separate oxp, right? So I could make a ship engines-OXP with only the script_info for each ship in the .plist, and it plays nicely with the shipdata.plists of other OXPs?
Using it via like_ship or shipdata-overrides.plist is no option, because it may discard existing script_info entries.
And the scriptInfo is read-only, so you can't expand/change it via script.
The option in BGS was added specifically for ship creators. To make it more flexible BGS could check if a playership has script properties with the same name (bgs_engine, bgs_engineUp, bgs_engineDown).
Re: Questions about making an audio OXP
Does that mean BGS can do that already and I have to tell it to, or that it will be able to do that in the future?Svengali wrote:The option in BGS was added specifically for ship creators. To make it more flexible BGS could check if a playership has script properties with the same name (bgs_engine, bgs_engineUp, bgs_engineDown).
Re: Questions about making an audio OXP
Yes, BGS reads the script_info keys since it was released in 2010.Corny wrote:Does that mean BGS can do that already and I have to tell it to, or that it will be able to do that in the future?
I'll add the checks for properties for the next version.
- pagroove
- ---- E L I T E ----
- Posts: 3035
- Joined: Wed Feb 21, 2007 11:52 pm
- Location: On a famous planet
Re: Questions about making an audio OXP
Svengali answered a lot of questions already. BGS was indead designed around the principle that it is modular. A plan I had was to make different engine sounds. However looping is tricky so you have to use a good sound editor for it. I use Soundforge but there are tons of audio editors out there.
For making sounds I use various forms/blends of sampling an synthesizers.
The output format of your sound has to be in .ogg. If your source material is in .wav then you can convert it to .ogg with programs such as (win)lame.
For making sounds I use various forms/blends of sampling an synthesizers.
The output format of your sound has to be in .ogg. If your source material is in .wav then you can convert it to .ogg with programs such as (win)lame.
For P.A. Groove's music check
https://soundcloud.com/p-a-groove
Famous Planets v 2.7. (for Povray)
https://bb.oolite.space/viewtopic.php?f=4&t=13709
https://soundcloud.com/p-a-groove
Famous Planets v 2.7. (for Povray)
https://bb.oolite.space/viewtopic.php?f=4&t=13709
Re: Questions about making an audio OXP
Thanks for the tips, pagroove. I'm working with Logic Pro 9, so I guess I have enough synthies to work with already.
For converting, I use Max, which can convert from and to every audio format I've ever heard of - plus a few more. Did I mention it's free and open source?
If anyone is looking for tools, be aware that both of these softwares are mac-only.
For converting, I use Max, which can convert from and to every audio format I've ever heard of - plus a few more. Did I mention it's free and open source?
If anyone is looking for tools, be aware that both of these softwares are mac-only.
- pagroove
- ---- E L I T E ----
- Posts: 3035
- Joined: Wed Feb 21, 2007 11:52 pm
- Location: On a famous planet
Re: Questions about making an audio OXP
For engine sounds a noise generator always comes in handy. If you got a synth with more oscillators then you can provide a low sine on osc1 and a noise generator on osc2 and then blend the sounds. Making sounds at different pitch already gives more variety in engine sounds.
When making sounds it always comes in handy to read about synthesis. .
When making sounds it always comes in handy to read about synthesis. .
For P.A. Groove's music check
https://soundcloud.com/p-a-groove
Famous Planets v 2.7. (for Povray)
https://bb.oolite.space/viewtopic.php?f=4&t=13709
https://soundcloud.com/p-a-groove
Famous Planets v 2.7. (for Povray)
https://bb.oolite.space/viewtopic.php?f=4&t=13709
-
- ---- E L I T E ----
- Posts: 607
- Joined: Wed Feb 20, 2013 1:24 am
- Location: Aboard the D.T.T Snake Charmer: My Xanadu
- Contact:
Re: Questions about making an audio OXP
Where do I need to put the sound (.ogg) files when I am setting this up?Svengali wrote:With BGS it is already possible to use a different set of sounds by simply adding script_info keys in shipdata.plist.Code: Select all
script_info = {"bgs_engine" = "myEngine.ogg"; "bgs_engineUp" = "myEngineUp.ogg"; "bgs_engineDown" = "myEngineDown.ogg";};
- Commander McLane
- ---- E L I T E ----
- Posts: 9520
- Joined: Thu Dec 14, 2006 9:08 am
- Location: a Hacker Outpost in a moderately remote area
- Contact:
Re: Questions about making an audio OXP
In a folder named "Sounds" in your OXP.Paradox wrote:Where do I need to put the sound (.ogg) files when I am setting this up?Svengali wrote:With BGS it is already possible to use a different set of sounds by simply adding script_info keys in shipdata.plist.Code: Select all
script_info = {"bgs_engine" = "myEngine.ogg"; "bgs_engineUp" = "myEngineUp.ogg"; "bgs_engineDown" = "myEngineDown.ogg";};
Re: Questions about making an audio OXP
Can I influence if a sound is looped? Is the length of a clip fixed?
E.g. I noticed that there's the clip in the BGS that says "scoop active", but it would always start the next loop after "scoop" already, so you hear the "...active" only when the scoop is actually no longer active. So... just making sure, the answers are "No" and "Yes" respectively?
E.g. I noticed that there's the clip in the BGS that says "scoop active", but it would always start the next loop after "scoop" already, so you hear the "...active" only when the scoop is actually no longer active. So... just making sure, the answers are "No" and "Yes" respectively?
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
Re: Questions about making an audio OXP
You can loop a sound by using theCorny wrote:Can I influence if a sound is looped? Is the length of a clip fixed?
E.g. I noticed that there's the clip in the BGS that says "scoop active", but it would always start the next loop after "scoop" already, so you hear the "...active" only when the scoop is actually no longer active. So... just making sure, the answers are "No" and "Yes" respectively?
loop
or repeatCount
property of SoundSource.The length of a clip is the length of the sound file.
You can play multiple overlapping copies of a sound using multiple sound sources playing the same sound. The BGS scoop case is happening because only one sound source is used for that sound, which is played periodically, and the sound provided is way too long.
E-mail: [email protected]
Re: Questions about making an audio OXP
Ah, that's awesome, thanks! I don't really get the length issue, though.
The length of the clip is the length of the sound file, but still the scoop-sound is too long...? How can it be too long if the length of the sound file defines the length of the clip? Or is it just the scooping interval (which calls the sound again) which is fixed?
The length of the clip is the length of the sound file, but still the scoop-sound is too long...? How can it be too long if the length of the sound file defines the length of the clip? Or is it just the scooping interval (which calls the sound again) which is fixed?
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
Re: Questions about making an audio OXP
For scooping in particular, the sound is played at a fixed interval using a single sound source.
E-mail: [email protected]