Author Topic: Submenu for stock ships.  (Read 3080 times)

Offline Kirk

  • Posts: 1438
  • Cookies: 139
    • My Released Mods
Submenu for stock ships.
« on: April 30, 2008, 01:38:30 AM »
Is there a way to force stock ships, ie nebula, BOP, into a submenu? Simply adding a submenu into the ships plugin doesn't work.

Offline JimmyB76

  • Posts: 6423
  • Cookies: 421
Re: Submenu for stock ships.
« Reply #1 on: April 30, 2008, 08:15:25 AM »
ya thats easy...

add this to the top of the stock ship's plugin (in scripts/custom/ships):
(this case being my stock galaxy, in my game under a "warships" submenu)
Code: [Select]
Foundation.ShipDef.Galaxy.SubMenu = "Warships"
such that it looks like this:
Code: [Select]
import Foundation
import App
Foundation.ShipDef.Galaxy.SubMenu = "Warships"

try that - if youre still stuck, upload the ship's plugin here :)

Offline MLeo

  • Retired Staff
  • Posts: 3636
  • Cookies: 833
  • Software Simian
    • the Programming Pantheon
Re: Submenu for stock ships.
« Reply #2 on: April 30, 2008, 11:08:31 AM »
I knew explaining it to you a couple of times would pay off! Thanks Jimmy!
I still can't read peoples minds, nor can I read peoples computers, even worse, I can't combine the two to read what is going wrong with your BC install...

"It was filed under 'B' for blackmail." - Morse, Inspector Morse - The dead of Jericho.

Offline JimmyB76

  • Posts: 6423
  • Cookies: 421
Re: Submenu for stock ships.
« Reply #3 on: April 30, 2008, 12:38:50 PM »
 lol   see?  youve taught me a number of things all these years! :D

Offline Kirk

  • Posts: 1438
  • Cookies: 139
    • My Released Mods
Re: Submenu for stock ships.
« Reply #4 on: May 02, 2008, 03:47:15 PM »
Worked perfectly, thanks guys :), though, for some unthinkable reason, when I corrected a mistake I made to the plugin for my BOP and added the submenu, it only recognized the icon name change I made until I deleted the .pyc. Enjoy your new cookie Jimmy!

Edit: Having a problem with the BOP plugin.

Offline JimmyB76

  • Posts: 6423
  • Cookies: 421
Re: Submenu for stock ships.
« Reply #5 on: May 02, 2008, 05:56:39 PM »
ok try this...  and if this doesnt work, i have one more idea...

Offline Kirk

  • Posts: 1438
  • Cookies: 139
    • My Released Mods
Re: Submenu for stock ships.
« Reply #6 on: May 02, 2008, 10:37:20 PM »
It didn't, but I figured it out. The long name was supposed to be "BOP." The displayed name, "Bird of Prey," comes from the TGL, I think.

Edit: Now I'm having trouble with the dry dock. All I have is what I need, and now I get a BSOD on startup.

Offline MLeo

  • Retired Staff
  • Posts: 3636
  • Cookies: 833
  • Software Simian
    • the Programming Pantheon
Re: Submenu for stock ships.
« Reply #7 on: May 04, 2008, 07:00:49 AM »
Mostlikely either DryDock doesn't exist, or it doesn't exist yet.

Add, below the import Foundation:
import StaticDefs
I still can't read peoples minds, nor can I read peoples computers, even worse, I can't combine the two to read what is going wrong with your BC install...

"It was filed under 'B' for blackmail." - Morse, Inspector Morse - The dead of Jericho.

Offline Kirk

  • Posts: 1438
  • Cookies: 139
    • My Released Mods
Re: Submenu for stock ships.
« Reply #8 on: May 04, 2008, 04:06:41 PM »
Mleo, how would I be able to tell what Dry Dock's name is? I checked the name of the ship file in script/ships, and it is DryDock. Would the name be inside the ship file?

Offline MLeo

  • Retired Staff
  • Posts: 3636
  • Cookies: 833
  • Software Simian
    • the Programming Pantheon
Re: Submenu for stock ships.
« Reply #9 on: May 04, 2008, 05:32:24 PM »
It's "Drydock" not "DryDock"
I still can't read peoples minds, nor can I read peoples computers, even worse, I can't combine the two to read what is going wrong with your BC install...

"It was filed under 'B' for blackmail." - Morse, Inspector Morse - The dead of Jericho.

Offline Kirk

  • Posts: 1438
  • Cookies: 139
    • My Released Mods
Re: Submenu for stock ships.
« Reply #10 on: May 04, 2008, 05:37:34 PM »
Aaah! That would cause a problem. As soon as I get to my home PC, I will try that out.

It worked, thanks MLeo.

Offline tiqhud

  • BCFiles File Poster
  • Posts: 1763
  • Cookies: 1067
  • San Francisco Shipyards (HPer) file manuiplater
Re: Submenu for stock ships.
« Reply #11 on: July 09, 2008, 10:50:21 AM »
might have to do this, later
TiqHud
you sir, are unable to strike, the port or starboard parts of hull , of a bovine storage facility.
Canon , what people argue exists, that doesn't really  exist.
It is all the little details, that cause headaches.
"Never judge wealth with Money"
'Intelligence has Nothing to do with Politics'
it is Late, Do you know where your Towel is?