Author Topic: Strange Sound Issue  (Read 1394 times)

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Strange Sound Issue
« on: May 07, 2018, 07:30:17 PM »
Recently I've been modifying the game while trying to keep it as 'Single-Player Friendly' as possible. I've been mostly successful and despite the countless modifications to scripts and hardpoints, the SP campaign is still fully playable.

I am, however, having one unusual problem. On my Sovereign class ship, which uses Pulse Weapons for Quantum Torpedoes, the sound for launching the Quantums sometimes doesn't play. It works 100% of the time in QuickBattle, and it works fine for the first SP mission I start up (through the 'Test Mode' option) but as soon as I complete a mission and load the next one, or if I load a saved game directly form the main menu, the Quantum Torpedoes are now silent.  :idk:

I don't have an issue with any of the ship's other weaponry, nor does this problem persist if I quit to the main menu and manually select the next mission through the Test Mode.

It's a minor problem but it is frustrating. Anyone experienced with SP modification have any insight on this?

Offline Morgan

  • Moderator
  • Posts: 1340
  • Cookies: 65535
Re: Strange Sound Issue
« Reply #1 on: May 08, 2018, 12:36:05 PM »
Dude, I'm running into the exact same thing!  I'm thinking it's something age related between BC's sound engine and modern sound card drivers for Windows 10, since I remember back in the day on Windows XP running the Maelstrom campaign with CG's Sovereign (which was also setup with pulse-fire quantums) without this happening.

The campaign install I created only consists of Basic Foundation, Mark's GUI mod (lite), BC Lost Dialog, and ship & hardpoint replacements.

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Re: Strange Sound Issue
« Reply #2 on: May 08, 2018, 11:24:56 PM »
Dude, I'm running into the exact same thing!  I'm thinking it's something age related between BC's sound engine and modern sound card drivers for Windows 10, since I remember back in the day on Windows XP running the Maelstrom campaign with CG's Sovereign (which was also setup with pulse-fire quantums) without this happening.

The campaign install I created only consists of Basic Foundation, Mark's GUI mod (lite), BC Lost Dialog, and ship & hardpoint replacements.

I have a similar install to you, but I do not run on Windows 10. I'm on Windows 8.1 here.

But yeah, I'm at a loss for what is causing this. I think it's something to do with how the game writes the save file... but that's just a guess.

Offline Morgan

  • Moderator
  • Posts: 1340
  • Cookies: 65535
Re: Strange Sound Issue
« Reply #3 on: May 09, 2018, 11:45:53 AM »
I'm not sure how the save files could cause this, but it's as good a guess as any.

BC's engine is quite old and there's always been little audio hiccups here and there - the bridge ambient sound cutting out occasionally, voice dialog muting the red alert klaxons sometimes.

Offline Tethys

  • -=USF=- Co-Leader
  • Posts: 256
  • Cookies: 89
Re: Strange Sound Issue
« Reply #4 on: May 09, 2018, 01:08:56 PM »
It is my experience, at least with most non-vanilla scripts, that sounds are programmed in the python, and perhaps there may be conflicts or errors in calling the function after save/load. I had a small issue where some functions would not reset after ship death, perhaps there is a relation.

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Re: Strange Sound Issue
« Reply #5 on: November 09, 2018, 12:57:39 PM »
Necroing my own thread, but...
I solved the sound issue, and it only took 6 months  :P

It seems as if there is a limit to the size of a sound file that can be re-loaded from a saved game. The Quantum Torpedo sound file that was not loading was particularly large at about 200kb compared to every other weapon SFX file which were around 50kb.
Editing the file and re-saving it with a lower bitrate reduced its size, solving the issue. The torpedo sound now plays correctly on a loaded save!

Mark this issue as solved for future reference.  :D

Offline Morgan

  • Moderator
  • Posts: 1340
  • Cookies: 65535
Re: Strange Sound Issue
« Reply #6 on: November 10, 2018, 12:41:19 PM »
I'm glad you got it worked out!  The sound file I've been using is only 33kb though, and I'm still having the problem.  I've attached the file - can you see if there's any issue with it?

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Re: Strange Sound Issue
« Reply #7 on: April 21, 2019, 04:53:06 PM »
Re-Necroing my thread.

Seems the problem wasn't solved after all. Much like Morgan said:

The sound file I've been using is only 33kb though, and I'm still having the problem.

The sound seems to load correctly when selecting from a mid-mission save file, but if an entirely new mission is started the Quantum torpedo launch will not play.  :s

I really don't know why this only happens with this one sound file, but it sure makes for an annoying little glitch.

Offline Blackrook32

  • BC Files Admin
  • Vice Administrator
  • Posts: 561
  • Cookies: 1077
    • Blackrook32's YouTube Channel
Re: Strange Sound Issue
« Reply #8 on: April 22, 2019, 05:09:02 PM »
Re-Necroing my thread.

Seems the problem wasn't solved after all. Much like Morgan said:

The sound seems to load correctly when selecting from a mid-mission save file, but if an entirely new mission is started the Quantum torpedo launch will not play.  :s

I really don't know why this only happens with this one sound file, but it sure makes for an annoying little glitch.

Make sure your codecs are up to date.  :readme:

This happens with outdated .mp3 and .wav files. I use the K-Lite Codec pack Win7x64, but there are versions for Win10. You can also use the AVS Video Editor, adding the sound file to a blank video, then extract the audio (.mp3 or .wav) with updated codecs.

Hope that helps. :thumbsup:


" Fortune Favors the Bold "

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Re: Strange Sound Issue
« Reply #9 on: April 22, 2019, 07:31:13 PM »
Make sure your codecs are up to date.  :readme:

This happens with outdated .mp3 and .wav files. I use the K-Lite Codec pack Win7x64, but there are versions for Win10. You can also use the AVS Video Editor, adding the sound file to a blank video, then extract the audio (.mp3 or .wav) with updated codecs.

Hope that helps. :thumbsup:

I consider myself fairly tech-savvy, but you've completely lost me here.  :idk:

What do I download? And where does it go? Are you referring to the general codecs for my PC's audio and video programs? If so, how does that relate to BC?

Thanks.

Offline Blackrook32

  • BC Files Admin
  • Vice Administrator
  • Posts: 561
  • Cookies: 1077
    • Blackrook32's YouTube Channel
Re: Strange Sound Issue
« Reply #10 on: April 22, 2019, 08:25:18 PM »
I consider myself fairly tech-savvy, but you've completely lost me here.  :idk:

What do I download? And where does it go? Are you referring to the general codecs for my PC's audio and video programs? If so, how does that relate to BC?

Thanks.

Related to older video games, audio & video codecs should be updated every five years IMO.

I learned this threw working on my BC: Generations project. At the time 2015, I was using a Win Vistax32 rig that I got in 2007. I started to notice some of my sound files using BC and other older games pre 2005, were sounding like static.

When I got my Win7x64 Alienware rig back in 2015, I had the same problem; with older game audio/video files not working. K-Lite corrected most of them, the rest, I used a video program to recompile, what older audio files I was using from other old PC games, in mods for BC.

I didn't offer a link to K-Lite Codecs, because I could not find the home page for it; not hard to Google though.

IMO K-Lite Codec it's the best one out their, that worked for me.


" Fortune Favors the Bold "

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Re: Strange Sound Issue
« Reply #11 on: April 22, 2019, 09:41:41 PM »
K-Lite corrected most of them, the rest, I used a video program to recompile, what older audio files I was using from other old PC games, in mods for BC.

Okay, but what do I actually do with the sound file that doesn't play after loads? Edit the file with an audio editing program (such as Audacity) and then re-compile it? Because I've done that yet the issue persists.

Keep in mind, the sound plays totally fine in Quickbattle and when i first start a SP mission. It only fails to play after completing the initially selected mission and then proceeding to the next mission.

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Re: Strange Sound Issue
« Reply #12 on: April 22, 2019, 11:09:02 PM »
OK, interesting development upon further testing.

It looks like it doesn't matter what projectile is placed in the "pulse weapon" slot for my ship. No matter the weapon, the sound file will not play upon loading a subsequent mission. Even placing photon torpedoes (identical to the main torpedo subsystem's torpedoes) still causes the weapon to be silent.

This leads me to believe that the issue has nothing to do with the sound files for the projectile in question, but has something to do with how the game saves and loads the players ship information upon continuing a mission. The game must not look for the sounds associated with a pulse weapon since the vanilla game does not include pulses on any of the stock SP ships.

Offline King Class Scout

  • Posts: 1775
  • Cookies: 893
  • the other half of SFRD
Re: Strange Sound Issue
« Reply #13 on: April 23, 2019, 04:31:33 PM »
I just thought of something.  check the hardpoint itself, manually, and make sure there's an entry in "fire sound".  i ran into this with an older mod, once.
OS novel fan

Coming Soon: King's Mod Tuning Shop

best line I've ever read
Me: mine [my bridges] would probably be simple to get the characters to use.  the only person that sits is the captian.
Baz: space is vast there[sic] legs will be tired by the time they get to the next planet

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Re: Strange Sound Issue
« Reply #14 on: April 23, 2019, 04:44:28 PM »
I just thought of something.  check the hardpoint itself, manually, and make sure there's an entry in "fire sound".  i ran into this with an older mod, once.

Yep. There is an entry.

Code: [Select]
QuantumTubes.SetFireSound("Quantum Torpedo 3")
And "Quantum Torpedo 3" corresponds to the name of the sound file which is also referenced in the projectile file.

Code: [Select]
def GetLaunchSound():
return("Quantum Torpedo 3")

Offline King Class Scout

  • Posts: 1775
  • Cookies: 893
  • the other half of SFRD
Re: Strange Sound Issue
« Reply #15 on: April 24, 2019, 05:06:45 AM »
okay, make sure the sound ITSELF is in the appropriate folder, check for name typos (because of python's infamous typo sensitivity) in case the file name got goofed, and that it's in a mono format; I'd read a few posts involving sound hiccups because of stereo files being used outside of the game music.

sometimes the smallest things can screw the whole game up, I've found.
OS novel fan

Coming Soon: King's Mod Tuning Shop

best line I've ever read
Me: mine [my bridges] would probably be simple to get the characters to use.  the only person that sits is the captian.
Baz: space is vast there[sic] legs will be tired by the time they get to the next planet

Offline vonfrank

  • Posts: 447
  • Cookies: 182
Re: Strange Sound Issue
« Reply #16 on: April 24, 2019, 07:03:47 PM »
okay, make sure the sound ITSELF is in the appropriate folder, check for name typos (because of python's infamous typo sensitivity) in case the file name got goofed, and that it's in a mono format; I'd read a few posts involving sound hiccups because of stereo files being used outside of the game music.

sometimes the smallest things can screw the whole game up, I've found.

The sound file is in the correct folder and it is also in MONO format.

Wouldn't that issue prevent the sound from playing at all though?

Offline King Class Scout

  • Posts: 1775
  • Cookies: 893
  • the other half of SFRD
Re: Strange Sound Issue
« Reply #17 on: April 25, 2019, 05:45:20 AM »
all I know is that I'd read somewhere that a stereo soundbyte for a weapons effect isn't recognized by BC's engine.  I think it also has to be an old fashioned "wav".  I've never had sound issues other than someone forgetting to put the name in for the file in all the right places, once.
OS novel fan

Coming Soon: King's Mod Tuning Shop

best line I've ever read
Me: mine [my bridges] would probably be simple to get the characters to use.  the only person that sits is the captian.
Baz: space is vast there[sic] legs will be tired by the time they get to the next planet