Bridge Commander Central

BC Forums => BC Modding => Topic started by: AKcrazy on April 30, 2010, 07:30:25 PM

Title: .wav for Projectile won't work...please advise
Post by: AKcrazy on April 30, 2010, 07:30:25 PM
Today's a good day to die... or to mod BC a bit.....BUT:

I just encountered a tiny little problem while I was trying to alter BC the way I'd like it to be... One of the torpedoes that came along with an Enterprise B-Mod won't play a launchsound, no matter what I try... The script doesn't seem to be the prob, since I tried the sound that I have choosen for it on various other projectiles. (The torp is called "Mark IV", but its scribt directs to a projectile named "DucatTMPPhot" I'm sorry mot to have the mod-authors name right now, I don't have I-net at home...so I'm sitting in an internetcafe right now...)  It's just an altered version of the "ZZST6Torp" (Only stretched it a bit to sound heavier) I used Cool Edit Pro to do so and saved in .wav-format. Somehow it still won't work. The "def getLaunchSound (and so on)" strings in the py.-file can't be the reason, I've double checked it several times now...(and yes, I deleted the .pyc before the alterations), so I assume the problem should be a wrong compression of the .wav or anything....(The original sound didn't play either before I started to alter it...)
So the question is clear: Does anybody know what I am doing wrong???
Help would be much apreciated!!!

(Sorry for possible language - mistakes....I'm german, my bad ^^ also sorry if the thread is not at the right location! And of course; sorry if this prob has already been discussed in another thread...If so: I didn't find it...my bad again...)

Tallyho!
Title: Re: .wav for Projectile won't work...please advise
Post by: Morgan on April 30, 2010, 07:38:29 PM
Can you please post the sound, torpedo, and soundpak file? That'll help out a lot.
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on April 30, 2010, 07:40:40 PM
mkay, I'll do so, but I don't have them at hand right now, so it will have to wait untill tomorrow...

Thanks for quick response!!!
Title: Re: .wav for Projectile won't work...please advise
Post by: ACES_HIGH on April 30, 2010, 07:49:01 PM
if it is saved in .wav, that's most likely your problem, I'm pretty sure BC uses .mp3 format
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on April 30, 2010, 08:07:29 PM
mmmh.... that's funny.... all the sounds in the folder are shown as .wav ... at least my Win7 tells me.... could you check that out? (I have no copy of BC here (Internetcafe), so I can't do so myself right now...)

Would be much apreciated!!! :D
Title: Re: .wav for Projectile won't work...please advise
Post by: limey BSc. on April 30, 2010, 08:21:20 PM
You need to make sure it's set to 22050Hz (bottom left if you're using Audacity).
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on April 30, 2010, 08:26:30 PM
22050....can't check that right now, but I'm pretty shure that would be it (since I have set my Cool Edit Pro to save with 44000Hz...)

Thanks!!!

I'll report back if that solved my prob!!!

Don't forget to boldly go where no man has gone before....and bring a towel :D
Title: Re: .wav for Projectile won't work...please advise
Post by: Maxloef on May 01, 2010, 04:18:55 PM
44.000 should work aswell it just needs to be 16 bit and MONO
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on May 02, 2010, 08:53:31 AM
Well now I am confused.... I saved the .wav with 22050Hz, 16bit and mono setting...still it won't work... I tried in with 8bit and mono as well and so on (allways PCM) but no joy so far... It still won't work with any other projectile... but as well no other sound will be played for that torpedo...(I tried different sounds that work with other projectiles)

Here is the projectile... mk4.py:

###############################################################################


import App

###############################################################################
#   Create(pTorp)
#   
#   Creates a photon torpedo.
#   
#   Args:   pTorp - the torpedo, ready to be filled-in
#   
#   Return:   zero
###############################################################################
def Create(pTorp):

   kGlowColor = App.TGColorA()
   kGlowColor.SetRGBA(255.0 / 255.0, 45.0 / 255.0, 0.0, 1.000000)   
   kCoreColor = App.TGColorA()
   kCoreColor.SetRGBA(255.0 / 255.0, 252.0 / 255.0, 100.0 / 255.0, 1.000000)

   # Params are:

   pTorp.CreateTorpedoModel(
               "data/Textures/Tactical/DucatST6Core.tga",
               kCoreColor,
               0.1,
               1.0,
               "data/Textures/Tactical/DucatST6Glow.tga",
               kGlowColor,
               1.0,
               0.8,
               0.8,
               "data/Textures/Tactical/TorpedoFlares.tga",
               kGlowColor,
               20,
               1.0,
               0.2)
   pTorp.SetDamage( GetDamage() )
   pTorp.SetDamageRadiusFactor(0.13)
   pTorp.SetGuidanceLifetime( GetGuidanceLifetime() )
   pTorp.SetMaxAngularAccel( GetMaxAngularAccel() )

   # Multiplayer specific stuff.  Please, if you create a new torp
   # type. modify the SpeciesToTorp.py file to add the new type.
   import Multiplayer.SpeciesToTorp
   pTorp.SetNetType (Multiplayer.SpeciesToTorp.PHOTON)

   return(0)

def GetLaunchSpeed():
   return(23.0)

def GetLaunchSound():
   return("mk4photon")

def GetPowerCost():
   return(20.0)

def GetName():
   return("Mk IV Photon")

def GetDamage():
   return 1600.0

def GetGuidanceLifetime():
   return 30.0

def GetMaxAngularAccel():
   return 0.99

def GetLifetime():
   return 100.0



And the attachment is the .wav-file ...I had to zip it because .wav is not allowed as an attachment....

(I even tried it with audacity, but still it's not working... :hithead:)

Hope anyone can fix it, would totally make my day!

Tallyho...

Title: Re: .wav for Projectile won't work...please advise
Post by: teleguy on May 02, 2010, 11:05:51 AM
I tested the sound file, it worked just fine. Did you create a sound plugin in scripts\custom\autoload?

Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on May 02, 2010, 12:39:15 PM
Nope....is it necessary??? I wasn't aware of that.... so how do I add it there? Or is it simple enough to do without any instructions?

(Thanks for your kind help!!!)
Title: Re: .wav for Projectile won't work...please advise
Post by: teleguy on May 02, 2010, 12:41:35 PM
The easiest way would be to use Bcut.
http://www.bcs-tng.com/portal/?q=bcut1.7.5released
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on May 02, 2010, 12:54:52 PM
Thanks teleguy...downloading now....I only hope that BCUT doesn't screw up my BC like BCMP used to... (Making a backup every five minutes is not my interpretation of fun... :D)

I'll report back tomorrow or so if I finally get the sound to work...(or not)

Title: Re: .wav for Projectile won't work...please advise
Post by: teleguy on May 02, 2010, 12:58:37 PM
No, BCUT doesn't screw up your install. It even includes it's own backup function and a tool to repair damage by BCMP.
Title: Re: .wav for Projectile won't work...please advise
Post by: Mario on May 02, 2010, 11:27:39 PM
Quote
Thanks teleguy...downloading now....I only hope that BCUT doesn't screw up my BC like BCMP used to... (Making a backup every five minutes is not my interpretation of fun...

If you're talking about disabling ship plugins or causing bsod's because of faulty ship plugins, then no.

What teleguy said it has an inbuilt feature which allows you to backup the most critical files and restore your game to a previous point in time if needed, much like windows system restore i.e.
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on May 03, 2010, 06:26:12 AM
Finally....it works!!! How could I have failed to see BCMP?!?!! :banghead: That little programm will keep me busy for a while....

Thanks to all of you for yer help! :yay:

Title: Re: .wav for Projectile won't work...please advise
Post by: 086gf on May 03, 2010, 02:38:56 PM
I hope you mean BCUT lol.
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on May 04, 2010, 08:36:30 AM
ahhhhh.....wupps....of course BCUT....d'ooooooooohhhhhhh.... :hithead:

(stupid abbreviations.... :facepalm:)
Title: Re: .wav for Projectile won't work...please advise
Post by: eclipse74569 on May 04, 2010, 01:17:53 PM
lol cookied, it's happened to the best of us :)

and welcome aboard
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on May 05, 2010, 09:07:57 AM
.....okay......now what the .... am I supposed to do with a cookie??? :idk: Sorry, stupid and off-topic question....again, but this is the first forum I joined that has cookies.... And my printer didn't produce anything eatable so far :D (Maybe I'll have to like switch polarity of...something and recompile the computer core and have my deflector to make something funny first, I don't know :idk: Maybe I'll better ask data or just push the selfdestruct button :hithead:))

(Sorry, already searched the help, but still I have no clues what cookies are for)

Anyway, THX eclipse74569 !!! :D

Title: Re: .wav for Projectile won't work...please advise
Post by: limey BSc. on May 05, 2010, 09:23:03 AM
.....okay......now what the .... am I supposed to do with a cookie??? :idk: Sorry, stupid and off-topic question....again, but this is the first forum I joined that has cookies.... And my printer didn't produce anything eatable so far :D (Maybe I'll have to like switch polarity of...something and recompile the computer core and have my deflector to make something funny first, I don't know :idk: Maybe I'll better ask data or just push the selfdestruct button :hithead:))

(Sorry, already searched the help, but still I have no clues what cookies are for)

Anyway, THX eclipse74569 !!! :D



Cookies are basically what Karma or Rep is on other forums. Except you can only give good cookies here, not bad ones.
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on May 05, 2010, 11:25:16 AM
Allright, I think I get it....But how do I give cookies? Can't find a button anywhere....


and back to topic for once: why won't some sounds that already have been plugged in (by other mods) play? I tried to alter the sound of a torpedo so that it would sound like another one that defenitly works (with sound) Although I didn't misspell it or anything, again the wav won't be played
(In this case, the sound is the Junktorp that comes along with KM 1.0)

(again, thanks for your kind advise!!!)

Title: Re: .wav for Projectile won't work...please advise
Post by: Dalek on May 05, 2010, 11:30:06 AM
You have to have posted 50 tiems before being able to give cookies.
Title: Re: .wav for Projectile won't work...please advise
Post by: AKcrazy on May 05, 2010, 11:31:23 AM
Ahh... ok that makes sense...thx Dalek!