Jump to content

[1.6.1] Soundtrack Editor 4.6 (2019-01-28)


pizzaoverhead

Recommended Posts

2 hours ago, Red Stapler said:

Post your playlist.cfg file and I'll take a look (should be in your ...\"Kerbal Space Program"\Playlists folder).

 

Spoiler

playlist
{
    name = Construction
    loop = True
    shuffle = True
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = concerto-for-viola-in-g
        track = concerto-for-4-violins
        track = RV-484
        track = adente-piano-02
        track = canon-in-d
    }
    playWhen
    {
        scene = VAB | SPH
    }
}
playlist
{
    name = Astronaut Complex
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_AstronautComplexAmbience
    }
    playWhen
    {
        scene = AstronautComplex
    }
}
playlist
{
    name = Credits
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_Credits
    }
    playWhen
    {
        scene = Credits
    }
}
playlist
{
    name = Mission control ambience
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_MissionControlMusic
    }
    playWhen
    {
        scene = MissionControl
    }
}
playlist
{
    name = Research complex ambience
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_ResearchAndDevelopment
    }
    playWhen
    {
        scene = RnDComplex
    }
}
playlist
{
    name = Tracking station ambience
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_TrackingStation
    }
    playWhen
    {
        scene = TrackingStation
    }
}
playlist
{
    name = Space
    loop = True
    shuffle = True
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = spring-allegro-01
        track = adagio-in-g-minor
        track = winter-allegro-01
        track = concerto-for-oboe-in-d-minor
        track = adagietto-symphony-5
        track = blue-danuben
        track = air-on-G-string
        track = waltz-of-the-flowers
    }
    playWhen
    {
        inAtmosphere = False
        scene = LoadingBuffer | Flight | PSystem
    }
}
playlist
{
    name = Menu Ambience
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    playAfter = Menu theme
    tracks
    {
        track = KSP_MenuAmbience
    }
    playWhen
    {
        scene = MainMenu
    }
}
playlist
{
    name = Menu theme
    loop = False
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = True
    tracks
    {
        track = KSP_MainTheme
    }
    playWhen
    {
        scene = MainMenu
    }
}
playlist
{
    name = Space Center Ambience Day
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = dobroide-forest
    }
    playWhen
    {
        timeOfDay = TwilightAM | DayAM | DayPM
        scene = SpaceCentre
    }
}
playlist
{
    name = Space Center Ambience Night
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = dobroide-night-forest
    }
    playWhen
    {
        timeOfDay = NightAM | TwilightPM | NightPM
        scene = SpaceCentre
    }
}
playlist
{
    name = Pre-Launch Day
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = dobroide-forest
    }
    playWhen
    {
        timeOfDay = TwilightAM | DayAM | DayPM
        scene = Flight
        situation = PRELAUNCH
        bodyName = Kerbin
    }
}
playlist
{
    name = Pre-Launch Night
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = dobroide-night-forest
    }
    playWhen
    {
        timeOfDay = NightAM | TwilightPM | NightPM
        scene = Flight
        situation = PRELAUNCH
        bodyName = Kerbin
    }
}

 

 

Link to comment
Share on other sites

1 hour ago, IxC999 said:

 

  Hide contents

playlist
{
    name = Construction
    loop = True
    shuffle = True
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = concerto-for-viola-in-g
        track = concerto-for-4-violins
        track = RV-484
        track = adente-piano-02
        track = canon-in-d
    }
    playWhen
    {
        scene = VAB | SPH
    }
}
playlist
{
    name = Astronaut Complex
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_AstronautComplexAmbience
    }
    playWhen
    {
        scene = AstronautComplex
    }
}
playlist
{
    name = Credits
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_Credits
    }
    playWhen
    {
        scene = Credits
    }
}
playlist
{
    name = Mission control ambience
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_MissionControlMusic
    }
    playWhen
    {
        scene = MissionControl
    }
}
playlist
{
    name = Research complex ambience
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_ResearchAndDevelopment
    }
    playWhen
    {
        scene = RnDComplex
    }
}
playlist
{
    name = Tracking station ambience
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = KSP_TrackingStation
    }
    playWhen
    {
        scene = TrackingStation
    }
}
playlist
{
    name = Space
    loop = True
    shuffle = True
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = spring-allegro-01
        track = adagio-in-g-minor
        track = winter-allegro-01
        track = concerto-for-oboe-in-d-minor
        track = adagietto-symphony-5
        track = blue-danuben
        track = air-on-G-string
        track = waltz-of-the-flowers
    }
    playWhen
    {
        inAtmosphere = False
        scene = Flight
    }
}
playlist
{
    name = Menu Ambience
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    playAfter = Menu theme
    tracks
    {
        track = KSP_MenuAmbience
    }
    playWhen
    {
        scene = MainMenu
    }
}
playlist
{
    name = Menu theme
    loop = False
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = True
    tracks
    {
        track = KSP_MainTheme
    }
    playWhen
    {
        scene = MainMenu
    }
}
playlist
{
    name = Space Center Ambience Day
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = dobroide-forest
    }
    playWhen
    {
        timeOfDay = TwilightAM | DayAM | DayPM
        scene = SpaceCentre
    }
}
playlist
{
    name = Space Center Ambience Night
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = dobroide-night-forest
    }
    playWhen
    {
        timeOfDay = NightAM | TwilightPM | NightPM
        scene = SpaceCentre
    }
}
playlist
{
    name = Pre-Launch Day
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = dobroide-forest
    }
    playWhen
    {
        timeOfDay = TwilightAM | DayAM | DayPM
        scene = Flight
        situation = PRELAUNCH
        bodyName = Kerbin
    }
}
playlist
{
    name = Pre-Launch Night
    loop = True
    shuffle = False
    preloadTime = 5
    pauseOnGamePause = True
    disableAfterPlay = False
    tracks
    {
        track = dobroide-night-forest
    }
    playWhen
    {
        timeOfDay = NightAM | TwilightPM | NightPM
        scene = Flight
        situation = PRELAUNCH
        bodyName = Kerbin
    }
}

 

See bolded text above...that is the way my 'Space' playlist is setup and it works both in space (Flight) and when in the map mode (which should also be Flight).  LoadingBuffer and PSystem may be affecting it playing in map mode...not sure why that would be the case, but that is the only thing I can think of as I compare vs my playlist.cfg.  :)  

I hope it resolves your issue. 

 

 

Link to comment
Share on other sites

2 hours ago, IxC999 said:

sadly the issue still persists, I'm not sure what's going on but thank u v much for the attempt at helping me out  :D

No worries.  I checked your playlist again and it looks fine. 

But, just to double check... when you say the Map, you are talking about the one from Space or Flight, not the one from the Tracking Station, right?  I'm dense sometimes. :)

 

Also, one last thing to try for process of elimination if you want (I just did on a 1.7 vanilla install and map worked fine there)...use the original playlists.cfg file and music from Soundtrack Editor to see if it works. If it does, then something else is messing it up.  Good luck!

Edited by Red Stapler
Link to comment
Share on other sites

10 hours ago, Red Stapler said:

No worries.  I checked your playlist again and it looks fine. 

But, just to double check... when you say the Map, you are talking about the one from Space or Flight, not the one from the Tracking Station, right?  I'm dense sometimes. :)

 

Also, one last thing to try for process of elimination if you want (I just did on a 1.7 vanilla install and map worked fine there)...use the original playlists.cfg file and music from Soundtrack Editor to see if it works. If it does, then something else is messing it up.  Good luck!

yes! the music mutes in the ingame map mode, the volume on the music player is the same, and the mute option is off. i'll put soundtrack editor on a clean install today and see if i get different results :P

Link to comment
Share on other sites

I've noticed that none of the windows in this mod respect the F2 "hide GUI" command, which is annoying for taking those cinematic screenshots.  Have others noticed this as well?

Another issue that I am having is the tracks in a playlist no longer autoplay if use the 'next track' button in the playlist, instead I need to manually advance to the next song.

Edited by captainb
Link to comment
Share on other sites

  • 3 weeks later...

Any chance an option could be added for minimum or maximum timewarp setting to play a given playlist? I play with Kerbal Construction Time (for Realism Overhaul) and having the system switching day/night KSC playlists constantly is both performance-intensive and annoying, and I ended up having to switch to a single playlist for day and night. Additionally, being able to play some effect or song while timewarping would be neat.

Also, would fade-out/fade-in instead of an abrupt transition between playlists be possible?

Edited by Ithirahad
Link to comment
Share on other sites

  • 1 month later...

 

Is development on this mod dead? I am using it in version 1.7.3 and it is working well.  

I have a request though. Is it possible to add another selector to qualifiers for when a playlist is activated? I would like to restrict the playlist by craft type. Currently, every time my kerbal hops, or bounces, my dramatic orchestral launch music wants to start playing, only to be interrupted by the kerbal landing back on the ground. 

Having a craft selection would prevent that, and allow me to create a playlist for my aircraft in flight that is separate from my rocket launch playlist.

And, thanks for this terrific mod - it has really help enhance the immersiveness of the game. I do hope it is still being worked on.

 

Link to comment
Share on other sites

  • 1 month later...
6 hours ago, jpinard said:

Has anyone noticed any kind of performance hit from having the game watch for all the different states to trigger music?

Not for me, but if you have a bunch of stuff playing (playlists with many songs) it can suck up your ram until you change situations/new track list loads.   Or if you have lots of mods, maybe you are at the top of your ram capabilities and a long playlist on Soundtrack Editor pushes it over and you get a performance hit.   

My best 2 guesses.  Good luck!

Edited by Red Stapler
Link to comment
Share on other sites

  • 2 weeks later...
On 8/30/2019 at 7:45 PM, jpinard said:

Has anyone noticed any kind of performance hit from having the game watch for all the different states to trigger music?

Most of these are pretty lightweight. They use the KSP events system, so there is no extra work done until KSP taps the event handler on the shoulder to let it know that something has happened. The numeric checks (max/min altitude/speed etc.) have to be done more frequently, but checking if one number is greater than another is something computers can do very quickly. If you're having any problems, leave some details and I'll see if there's anything that can be done about it.

On 8/31/2019 at 2:18 AM, Red Stapler said:

Not for me, but if you have a bunch of stuff playing (playlists with many songs) it can suck up your ram until you change situations/new track list loads.   Or if you have lots of mods, maybe you are at the top of your ram capabilities and a long playlist on Soundtrack Editor pushes it over and you get a performance hit.   

My best 2 guesses.  Good luck!

The way it's designed, playlists should only load the song that is currently playing, then unload it when it's done. If you're seeing large RAM usege with big playlists, that's a problem that needs fixed. What could have that effect is if the tracks you're using are very long. If you have a track that's an hour long, that will have more of an effect than one that's two minutes long.

Link to comment
Share on other sites

  • 2 weeks later...
On 9/11/2019 at 5:00 AM, pizzaoverhead said:

Most of these are pretty lightweight. They use the KSP events system, so there is no extra work done until KSP taps the event handler on the shoulder to let it know that something has happened. The numeric checks (max/min altitude/speed etc.) have to be done more frequently, but checking if one number is greater than another is something computers can do very quickly. If you're having any problems, leave some details and I'll see if there's anything that can be done about it.

The way it's designed, playlists should only load the song that is currently playing, then unload it when it's done. If you're seeing large RAM usege with big playlists, that's a problem that needs fixed. What could have that effect is if the tracks you're using are very long. If you have a track that's an hour long, that will have more of an effect than one that's two minutes long.

Fantastic.  Thank you!

Link to comment
Share on other sites

On 6/1/2019 at 9:04 PM, captainb said:

I've noticed that none of the windows in this mod respect the F2 "hide GUI" command, which is annoying for taking those cinematic screenshots.  Have others noticed this as well?

Another issue that I am having is the tracks in a playlist no longer autoplay if use the 'next track' button in the playlist, instead I need to manually advance to the next song.

Getting the same thing, sporadically. I noted each time it was accompanied by this from the Log:

[EXC 03:29:53.336] ArgumentOutOfRangeException: Argument is out of range.
Parameter name: index
	System.Collections.Generic.List`1[UnityEngine.AudioClip].get_Item (Int32 index)
	MusicLogic+<PlayList>c__Iterator2.MoveNext ()
	UnityEngine.SetupCoroutine.InvokeMoveNext (IEnumerator enumerator, IntPtr returnValueAddress)
	UnityEngine.MonoBehaviour:StartCoroutine(IEnumerator)
	MusicLogic:ConstructionMusic(EditorFacility)
	<OnLevelLoaded>c__Iterator0:MoveNext()
	UnityEngine.SetupCoroutine:InvokeMoveNext(IEnumerator, IntPtr)

From what I can see, it's generating an ArgumentOutOfRangeException when the Iterator tries to do the MoveNext function. Weird thing is that it occurs in odd circumstances. (not while flying in atmosphere, but errors in the Editor, R&D complex, or in Space)

Possibly due to the way the playlist files are being processed? I'll try looking into it and see if I can sort things out. I simply CANNOT play this game with music enabled without this Mod! The same old tired tracks repeating for hours on end grates on my nerves!

Link to comment
Share on other sites

After extensive testing, (including 3 Crashes to desktop) I tried removing the libmpg123-0.dll from the KSP_x64_Data\Mono directory and converting all my music over to ogg...

Bingo! No more AOR errors and music never gets hung up such that it won't advance to the next track... and that with nearly 200 music tracks and dozens of flight scenes. (I haven't tested ALL of them yet, but the ones that were getting hung up are fixed, so I suspect that the others will be working now too)

I'll continue testing to be sure, but if anyone is getting a lot of errors and Crash to desktop you might try doing the same thing and see if it resolves your issues.

Edit: Just did a full-up test with the game successfully switching from Editor to Pre-launch to Flight to Suborbital to Orbital, then reversed to Suborbital to Flight to Splashed without a hitch and no errors in the log.

I think we have the problem nailed... it may well be the libmpg123-0.dll that's throwing the errors, even if you're not playing an MP3.

Edited by RobertaME
Update
Link to comment
Share on other sites

  • 1 month later...

@pizzaoverhead

I was looking at this for my new career.  Since no 1.8 version was available, I rebuilt it for myself.

I noticed there are two lines which use deprecated methods:

                WWW www = new WWW("file://" + filePath);
                AudioClip clip =  //UnityEngine.WWWAudioExtensions.GetAudioClip(www);
                www.GetAudioClip();

and the issue is:

D:\Users\jbb\github\SoundtrackEditor\SoundtrackEditor\AudioLoader.cs(97,17,97,20): warning CS0618: 'WWW' is obsolete: 'Use UnityWebRequest, a fully featured replacement which is more efficient and has additional features'
D:\Users\jbb\github\SoundtrackEditor\SoundtrackEditor\AudioLoader.cs(97,31,97,34): warning CS0618: 'WWW' is obsolete: 'Use UnityWebRequest, a fully featured replacement which is more efficient and has additional features'

 

While the change on the three lines is simple, it becomes more complex because the UnityWebRequest requires that it be done in a CoRoutine.

This change isn't absolutely required, the current code works fine in 1.8, but any future version of Unity is going to force this to be changed.  Since this is only loading a file from local disk, I'm going to see if I can simply load the file directly.  

which leads to the question: 

  • Why did you decide to use the WWW class instead of loading directly from disk?
Link to comment
Share on other sites

On 11/7/2019 at 1:37 PM, linuxgurugamer said:

@pizzaoverhead

I was looking at this for my new career.  Since no 1.8 version was available, I rebuilt it for myself.

I noticed there are two lines which use deprecated methods:

While the change on the three lines is simple, it becomes more complex because the UnityWebRequest requires that it be done in a CoRoutine.

This change isn't absolutely required, the current code works fine in 1.8, but any future version of Unity is going to force this to be changed.  Since this is only loading a file from local disk, I'm going to see if I can simply load the file directly.  

which leads to the question: 

  • Why did you decide to use the WWW class instead of loading directly from disk?

How would I fix this myself?

Link to comment
Share on other sites

1 hour ago, linuxgurugamer said:

It's not an easy fix, the basic logic needs to be reworked

So how? I get an error if I try to recompile:
 

error CS0619: 'WWWAudioExtensions.GetAudioClip(WWW)' is obsolete: 'WWWAudioExtensions.GetAudioClip extension method has been replaced by WWW.GetAudioClip instance method. (UnityUpgradable) -> WWW.GetAudioClip()'

 

Link to comment
Share on other sites

6 hours ago, PyjackMeat said:

So how? I get an error if I try to recompile:
 


error CS0619: 'WWWAudioExtensions.GetAudioClip(WWW)' is obsolete: 'WWWAudioExtensions.GetAudioClip extension method has been replaced by WWW.GetAudioClip instance method. (UnityUpgradable) -> WWW.GetAudioClip()'

 

Replace that line with:

 AudioClip clip = www.GetAudioClip();

You will then get messages that www is obsolete, but it should work .  It will eventually need to be replaced totally

Link to comment
Share on other sites

  • 2 months later...
On 11/17/2019 at 7:13 PM, linuxgurugamer said:

All, I am working on adopting this mod

 

Edit: I heard from @pizzaoverhead early this morning, he is still interested in continuing this mod.  So the adoption is on hold for the foreseeable future

It's been nearly three months.  Not trying to bother, but it would be nice to have this mod so I don't go absolutely crazy having to listen to that damn VAB music even though I have music turned all the way down in the settings menu.

If you're still interested in adopting it, what remains of my sanity would be eternally grateful.

In lieu of that, if anyone can point me in the direction of how to ACTUALLY disable the music ALL of the time, even if it involves deleting the damn sound files, that would work too.

Link to comment
Share on other sites

1 hour ago, DeliriumTrigger said:

It's been nearly three months.  Not trying to bother, but it would be nice to have this mod so I don't go absolutely crazy having to listen to that damn VAB music even though I have music turned all the way down in the settings menu.

If you're still interested in adopting it, what remains of my sanity would be eternally grateful.

In lieu of that, if anyone can point me in the direction of how to ACTUALLY disable the music ALL of the time, even if it involves deleting the damn sound files, that would work too.

I do concur though I've found what's most tolerable (and doesn't have abrupt shifts when you leave scenes) is a couple of different Spotify playlists- I have one for building and one for space and honestly I just swap between them when I feel the calling, Its definitely not preferred but its what I make do with without Soundtrack Editor :)

Link to comment
Share on other sites

6 minutes ago, Avera9eJoe said:

I do concur though I've found what's most tolerable (and doesn't have abrupt shifts when you leave scenes) is a couple of different Spotify playlists- I have one for building and one for space and honestly I just swap between them when I feel the calling, Its definitely not preferred but its what I make do with without Soundtrack Editor :)

Yeah I have plenty of music to listen to while playing.  The problem is that despite turning the music completely down in the settings menu, from time to time the game just ignores that and starts playing the music anyway.  Which is really weird, and annoying when other music is playing.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...