Author Topic: Is anything hardcoded?  (Read 2859 times)

0 Members and 1 Guest are viewing this topic.

Offline sausage

  • 24
    • waynejohnson.net
Is anything hardcoded?
When modding freespace 2 open, is there anything that is hardcoded that cannot be changed? For example, excluding animations and wave files, could I:

* Replace all Shivan text references and usage to a race of my own design?

I would imagine changing all references in all tables, missions and any other text file that it appears (all in a mod folder). Or is "Shivan" coded somewhere in the binaries that would break the game if I was to do something like this?

 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: Is anything hardcoded?
That should be easy enough to do in a mod, sure.

I am somewhat curious as to why you'd want to since they'd still be obviously Shivan.

 

Offline Spoon

  • 212
  • ヾ(´︶`♡)ノ
Re: Is anything hardcoded?
You don't need to replace the shivans, you can create a new race if you want as well.
Just mess around with Species_defs.tbl

But yeah, Shivan's are not hardcoded. You can replace them completely if you really want to.
Urutorahappī!!

[02:42] <@Axem> spoon somethings wrong
[02:42] <@Axem> critically wrong
[02:42] <@Axem> im happy with these missions now
[02:44] <@Axem> well
[02:44] <@Axem> with 2 of them

 

Offline Topgun

  • 210
Re: Is anything hardcoded?
sexps are hard-coded, maximum ships is hard-coded (for now). that's all I can think of off the top of my head.

 

Offline FUBAR-BDHR

  • Self-Propelled Trouble Magnet
  • 212
  • Master Drunk
    • 165th Beer Drinking Hell Raisers
Re: Is anything hardcoded?
Ship classes is a big one (cruiser, freighter, fighters etc).  Don't try to change those or you will run into issues. 
Most of the interface is hard coded at lest the file names.
There are still some hard coded effect names but you can change what the do
Some sound effects.
Couple of model names (debris and the full nebula model I believe)
A lot of HUD stuff but there are ways to change most of it.  Not that familiar with it.
Warp effects but there are at least 4 different ones. 



No-one ever listens to Zathras. Quite mad, they say. It is good that Zathras does not mind. He's even grown to like it. Oh yes. -Zathras

 

Offline Topgun

  • 210
Re: Is anything hardcoded?
you can't make new ship classes? I was pretty sure you could.

 

Offline sausage

  • 24
    • waynejohnson.net
Re: Is anything hardcoded?
Guys, thank you so much for the replies. What I'm aiming to do at some point is basically "skinning" FS2. Ie, making a mod where the names of the three races are different, change the ship names, and models (but not classes) and leave the campaign exactly the same.

Might not be something I do for a while but I can start thinking about it in the meantime.

 

Offline Topgun

  • 210
Re: Is anything hardcoded?
its too much work to be worth is IMO. you would have to edit every single mission to change the dialog ect. if you want to replace every ship, yeah you can do that, it would probably ruin game balance and be more work than what its worth, but you can do that.
much better to add your own ships and make your own missions.

 

Offline sausage

  • 24
    • waynejohnson.net
Re: Is anything hardcoded?
I suppose so.

I guess what I am really aiming to do (and this will no doubt draw much disgust from many people, I don't know)...

Diaspora or Btrl are probably still a long time away, and are going to be a very rich experience with all the complex alterations those guys are doind under the hood. For now, I just want to fly a viper and knock out a few cylon raiders as I'm sure many of us would like to do.

I though of swapping out the models, the names, auto searching and replacing where I could. I haven't been around long enough to know if this is all taboo.

 

Offline Topgun

  • 210
Re: Is anything hardcoded?
replace the Ulysses model with the viper one, problem solved.
and, I thought you where going to replace the ships with models you havn't made yet, if they are premade models, like the viper, its not that big of a deal.

 

Offline sausage

  • 24
    • waynejohnson.net
Yes, that should solve the itch :). I'd still like to have the names on the HUD changed too. I guess the other issue is finding people who have made the models, like the viper and raider and asking permission. I have to finish my first idea first before this one so I'm just thinking out loud.

 

Offline FUBAR-BDHR

  • Self-Propelled Trouble Magnet
  • 212
  • Master Drunk
    • 165th Beer Drinking Hell Raisers
you can't make new ship classes? I was pretty sure you could.

You can but they won't work correctly.  All the existing class behaviors are hard coded so you will end up with a rather stupid ship that doesn't do much unless explicitly scripted. 
No-one ever listens to Zathras. Quite mad, they say. It is good that Zathras does not mind. He's even grown to like it. Oh yes. -Zathras

 

Offline Aardwolf

  • 211
  • Posts: 16,384
Uh... isn't that what object_types.tbl is for?

 

Offline FUBAR-BDHR

  • Self-Propelled Trouble Magnet
  • 212
  • Master Drunk
    • 165th Beer Drinking Hell Raisers
Nope.  Again you can define them but since the behaviors are hard coded off of the FS2 object types you end up with ships that don't work correctly. 
No-one ever listens to Zathras. Quite mad, they say. It is good that Zathras does not mind. He's even grown to like it. Oh yes. -Zathras

 

Offline Dragon

  • Citation needed
  • 212
  • The sky is the limit.
For now, Objecttypes.tbl is more for changing already existing classes than for creating new ones.

 

Offline Sushi

  • Art Critic
  • 211
Nope.  Again you can define them but since the behaviors are hard coded off of the FS2 object types you end up with ships that don't work correctly. 

I know Wanderer's been working on a patch to fix that (it gives total control over object types) but it isn't committed yet. Probably to avoid the kind of mess I ended up creating with ai.tbl. :doubt:

 

Offline Topgun

  • 210
Yes, that should solve the itch :). I'd still like to have the names on the HUD changed too. I guess the other issue is finding people who have made the models, like the viper and raider and asking permission. I have to finish my first idea first before this one so I'm just thinking out loud.
that's a little harder. you need to replace the ship name in each mission to get that to work, too much work for what you get IMO.

 

Offline Droid803

  • Trusted poster of legit stuff
  • 213
  • /人 ◕ ‿‿ ◕ 人\ Do you want to be a Magical Girl?
    • Skype
    • Steam
ctrl + f
ctrl +v
x 1000000

Takes a while but not TOO hard.
(´・ω・`)
=============================================================

 

Offline Sushi

  • Art Critic
  • 211
It's even quick if you use an editor with some sort of find & replace.

:%s/foo/bar/g in vim. :)

  

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
If you're suggesting converting the main campaign into a BSG 'skin', that probably won't work; it'd be less work to just make your own BSG campaign.