Bridge Commander Central
BC Forums => BC Technical Support => Solved Problems => Topic started by: Billz on February 08, 2007, 06:59:11 PM
-
This never really bothered me before but I thought I might aswell try it.
Basically, all my custom species ships (Borg Ships, Kazon Ships, Dominion Ships etc.) use the default warp sfx sounds (ie: the sounds used for the ships in the 'Other Ships' selection menu).
I know the borg warp sfx sounds are avaliable with NanoFX2, but my borg ships wont use it, or their warp flashes (borg have green warp flashes according to KM, but my ones use the stupid purple effects).
What do I need to change in the NanoFX2 scripts so that all my custom species use their appropiate warp sounds and effects (provided I can find them)?
-
I think it isn't NanoFX at fault.
Do your borg ships use Foundation.BorgShipDef in their plugins?
-
I think it isn't NanoFX at fault.
Do your borg ships use Foundation.BorgShipDef in their plugins?
I just did a search using NotePad for 'Foundation.BorgShipDef' and it didnt find anything along that line so Im guessing thats the reason why the custom warp sound isnt working for it. Am I right and if so, should I change it and all my other ships plugins accordingly?
-
My (edited) Foundation has a BorgShipDef (and the Fed defs too), and NanoFXLIB.py would define the color of the plasma/warp blowup color. You want my Foundation.py? (If this is a KM install, don't ask)
-
My (edited) Foundation has a BorgShipDef (and the Fed defs too), and NanoFXLIB.py would define the color of the plasma/warp blowup color. You want my Foundation.py? (If this is a KM install, don't ask)
(This isnt a KM install)
If you think your edited pys will help and also teach me how to do it myself, then yeah, please send them on over.
-
The Following Foundation.py file includes additional defs that support the Stock Fed vessels, Vorcha, BoP, and a RemanShipDef, and not forgetting the Cube.
NanoFXLib.py contains a additional line (adds the Reman colors)
Now, to add a ShipDef (make sure Foundation isn't just one whole line in WordPad, or things get crappy from there),
we do this:
YourRace = RaceDef('FullRaceName', 'ShortRaceName')For ShortRaceName, simple: (Dominion has it as "Dom")
then jam this code below in the file:
class YourRaceShipDef(ShipDef):
def __init__(self, abbrev, species, dict):
dict['race'] = YourRace #(full name)
ShipDef.__init__(self, abbrev, species, dict)
NanoFX_Lib does some stuff, but also contains the plasma/warp blowup colors:
try:
dRGB = { "Federation" : ( 55.0, 120.0, 255.0),
"Klingon" : (255.0, 20.0, 0.0),
"Romulan" : ( 0.0, 248.0, 130.0),...
Use RGB, and put "YourRaceName" in the name (or else it defaults).
I havnt' found the WarpSFX just yet, but I'll somehow find it...
-
Hold it, hold it.
The "stock" Foundation.py (since BCMP 4.4, my own first BCMP/Foundation version) already includes a BorgShipDef, hence NanoFX has support for it.
There is also a DominionShipDef.
If you would have searched for just BorgShipDef you would have found it. ;)
-
I dont understand. I have searched in Foundation.py for BorgShipDef, found it, but theres nothing in there telling it which warp sounds or flashes to use. What am I supposed to be looking for?
Im using the foundation that comes with BCMI.net since that is the latest one.
-
I dont understand. I have searched in Foundation.py for BorgShipDef, found it, but theres nothing in there telling it which warp sounds or flashes to use. What am I supposed to be looking for?
The colours for the default races are defined in scripts/Custom/NanoFXv2/NanoFX_Lib.py, see GetRaceTextureColor for an example.
If you make your Borg ship use BorgShipDef then it will feature the correct colours and sounds.
Im using the foundation that comes with BCMI.net since that is the latest one.
They are identical. :P
All Foundation "upgrades" should _not_ modify Foundation.py. For example, FoundationTriggers. It doesn't modify Foundation.py, but each trigger inherits from Foundation.TriggerDef.
If you want to add your own races and stuff. Make it an extra file which you put in Autoload, and import (to be sure) in each of your new ShipDefs. And then use it.
-
If you make your Borg ship use BorgShipDef then it will feature the correct colours and sounds.
So how do I do that then?
-
So how do I do that then?
Open your ship plugin (scripts/Custom/Ships) and look for ShipDef
Now, look a bit to the left and see Foundation.
From the . onwards, replace what you see with Borg (untill you see ShipDef that is).
In the end that section will look like this:
Foundation.BorgShipDef(
If you can't work it out, put the plugin up here.
-
So how do I do that then?
Open your ship plugin (scripts/Custom/Ships) and look for ShipDef
Now, look a bit to the left and see Foundation.
From the . onwards, replace what you see with Borg (untill you see ShipDef that is).
In the end that section will look like this:
Foundation.BorgShipDef(
If you can't work it out, put the plugin up here.
Here.
I am sorry to be a pain about this but my scripting knowledge goes about as far as being able to make submenus and renaimng ships in their plugin files.
-
This is what I was refering to:
Foundation.ShipDef.CRCube = Foundation.ShipDef(abbrev, species, { 'name': longName, 'iconName': iconName, 'shipFile': shipFile })
It changes into:
Foundation.ShipDef.CRCube = Foundation.BorgShipDef(abbrev, species, { 'name': longName, 'iconName': iconName, 'shipFile': shipFile })
As seen in the file I added here.
-
This is what I was refering to:
Foundation.ShipDef.CRCube = Foundation.ShipDef(abbrev, species, { 'name': longName, 'iconName': iconName, 'shipFile': shipFile })
It changes into:
Foundation.ShipDef.CRCube = Foundation.BorgShipDef(abbrev, species, { 'name': longName, 'iconName': iconName, 'shipFile': shipFile })
As seen in the file I added here.
I get it now. Thanks Mleo. I will make all my other ships changes accordingly.