Author Topic: some basic scripting questions  (Read 1808 times)

Offline King Class Scout

  • Posts: 1775
  • Cookies: 893
  • the other half of SFRD
some basic scripting questions
« on: August 29, 2009, 07:57:59 AM »
1. where are the stock weapon scripts, like basic projectiles and disruptor shots (otherwise, you'd have to ask permission for EVERYTHING)
2. do you have to ask permission from the mesh maker, as ususal, for redoing an un-hardpointed ship?
3. does a scratch hardpoint have to be saved in PYC in order for the MPE to read it? (it keeps ignoring my scratch hardpoints)
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 X_TheUnknown_X

  • Posts: 325
  • Cookies: 328
  • (Semi) Retired
Re: some basic scripting questions
« Reply #1 on: August 29, 2009, 08:24:58 AM »
Firstly, BC Scripting might be the best place to ask for scripting help. But to answer your questions:

1) The stock weapon scripts are just the ones named PhotonTorpedo, QuantumTorpedo, etc. Besides, you shouldn't have to ask permission to use someone else's torpedo script as a start as long as you don't copy any of their torpedo effects/settings (because all torpedo scripts hace the same parameters). Also, the BC SDK has a 'scripts' folder which has ALL the stock files in there. (it's under 'SDK/Build/Scripts/Tactical/Projectiles')

2) On BCFiles, if the mesh is under "Public Domain Meshes", then permission isn't required (as far as I know). For other meshes, a permissions section should be added in the readme or description. Otherwise seek the creators permission.

3) The Model Property Editor will open and save in .py and .pyc files. It's best to save in plain .py, because .pyc are magically created by Bridge Commander when you start the game. I don't know why MPE should ignore your hardpoints, unless there is nothing in them in the first place.

Offline KrrKs

  • Posts: 461
  • Cookies: 25
Re: some basic scripting questions
« Reply #2 on: August 29, 2009, 08:29:09 AM »
My MPE loads ".py" well. Try to load Hardpoints Manually and don't forget that the actual Subsystems are located in the "scene Root" Mesh property on the right.

Offline King Class Scout

  • Posts: 1775
  • Cookies: 893
  • the other half of SFRD
Re: some basic scripting questions
« Reply #3 on: August 29, 2009, 08:45:36 AM »
I leave my practice HP's with the model files on my desktop for easy access (as I did with the Gabriel).  the one I worked on was completely ignored, even though the file is there (it's not complete, of course, I needed a break).  MPE did the same thing to the Gabriel the minute I added a Plasma shot emergency weapon to the Gabe.  it completely ignored, and left totally blank, the hardpoint side, even with sceneroot on.

unknown: SDK?  lemmie guess, it's on the disk...i haven't gone through the disk's files, yet.

Edit: oh.  DUH!  sorry,  my head is empty sometimes :P
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 MLeo

  • Retired Staff
  • Posts: 3636
  • Cookies: 833
  • Software Simian
    • the Programming Pantheon
Re: some basic scripting questions
« Reply #4 on: August 29, 2009, 10:21:18 AM »
Considering 2 out of 3 questions are about hardpoints, Modding is the correct forum.
Only the first question is a Scripting question.



1. All stock py files are to be found in the SDK.
2. If the model comes as is, so without a hardpoint, then permission requirements can usually be found in the readme.
3. No, you only save in py format. Only BC will create a pyc, which you do not have to include if you want to redistribute your mod.
While MPE can load pyc files (if you specificly ask it to load one), it is important that you save your hardpoint in py and not pyc format, otherwise BC might crash, or worse, delete/overwrite your work.
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 King Class Scout

  • Posts: 1775
  • Cookies: 893
  • the other half of SFRD
Re: some basic scripting questions
« Reply #5 on: August 29, 2009, 02:06:17 PM »
*chuckles as translates your sub-title* appropriate.  at least YOUR coding skills aren't super antique, like mine (Basic, color basic [Tandy], some apple 2 coding)

I'm not gonna try and release it (it's the unused Klingon D9), but keep it for myself.  i colored it up, some, as plain greys are kinda bland.
I found my goof.  i had two copies of the ship property, deleted one, and it nailed both.

btw, your Diamond BC projectiles saved my butt with that one, I typoed in the HP.  too bad your shipdef tutorial thread is too old to reply to, I'm having a hard time understanding it.

thanks everybody, it's hard to know where to put issues like this.
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 MLeo

  • Retired Staff
  • Posts: 3636
  • Cookies: 833
  • Software Simian
    • the Programming Pantheon
Re: some basic scripting questions
« Reply #6 on: August 29, 2009, 02:37:14 PM »
What is the link to the ShipDef tutorial?

At any rate, you can use BCUT to create a new ship plugin.
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 King Class Scout

  • Posts: 1775
  • Cookies: 893
  • the other half of SFRD
Re: some basic scripting questions
« Reply #7 on: August 29, 2009, 04:40:16 PM »
my bad.

this old tutorial.  http://bc-central.net/forums/index.php/topic,3216.0.html
I've read it over several times, and I still get confused.
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 MLeo

  • Retired Staff
  • Posts: 3636
  • Cookies: 833
  • Software Simian
    • the Programming Pantheon
Re: some basic scripting questions
« Reply #8 on: August 29, 2009, 05:45:30 PM »
my bad.

this old tutorial.  http://bc-central.net/forums/index.php/topic,3216.0.html
I've read it over several times, and I still get confused.
Please elaborate on what confuses you (better direct it through a PM/email). And I'll see what I can improve.
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.