Important Message

You are browsing the archived Lancers Reactor forums. You cannot register or login.
The content may be outdated and links may not be functional.


To get the latest in Freelancer news, mods, modding and downloads, go to
The-Starport

Complex (and working) .sur files

The general place to discuss MOD''ing Freelancer!

Post Wed Aug 01, 2007 5:09 pm

Download my old (and rather buggy) FLModelTool from this here site It will open the sur and arrange the data in a meaningful way for you with option to export this as a text file.

This will let you see the object names etc rather than wading through hex files and the like, but not edit.

EDIT : Oh and this may help 'bodge' a shrink-wrap or home made shield shape add it as a normal mesh in the sur and rename part (with the CRC number) as the number normally associated with shields. This can be found from surImporter or FLModelTool. Normally the sheld is a triangle strip type not triangle mesh, it should be fine but I never tested this idea.

+++ out of cheese error - redo from start +++

Edited by - anton on 8/1/2007 6:16:02 PM

Edited by - anton on 8/1/2007 6:17:15 PM

Post Wed Aug 01, 2007 5:32 pm

ok i think i know what happened -

you've followed my explicit instructions, file name and .3db name same, object name different - but i neglected to mention that changing the filename/.3db and -not- the object name really is easiest.

why? because your cons_fix will be wrong if you change the object name without mirroring the change there, (sur_splicer or the exporter would both give valid results, with the correct object name) whereas signing the .3db with a CRC or something else like your nick or whatever doesn't require fixing the object name referenced in the consfix

phew! ok got it?
1. change the filename node, in string, to read Zomgbayz_lod1MyShipsCRC.3db
2. change the appropriate .3db node to be exactly the same (copy + paste is a wonder)
3. leave object name alone - it will have a stupid _lod1 stuck on the end, but it won't require rewriting the sur_splice file or importing a consfix from a re-exported model with corrected names.

sorry i'm so scatter brained - its been several months since i've gone through the process but it's coming back to me now

Anton - i did find that putting a shield bubble on my ships seems to help on collision, but i never ran any empirical tests on it. i would import a normal SUR and export just the shield bubble with its imported name (it escapes me but i think it was 80008, or some 8's and 0's anyway) and include it in my sur_splicer file after resizing it with flmodeltool -> also you can scale any .3db SUR as much as you want and its all good. i was using a shield-generator sur for a ground model before Argh 's build of the exporter came out

Edited by - Cold_Void on 8/1/2007 6:38:19 PM

Post Thu Aug 02, 2007 1:58 pm

Very many thanks once again guys, your help and quick response is much appreciated.

OK got both points, I will see what happens and report back.

All the best to both of you.

Roleplay: - the art of self-deceipt!

Post Wed Aug 08, 2007 2:31 pm

Hi Cold, Anton...

On importing a standard sur or a sur I made with shield bubbles and then resize using FL Model Tool, I can see in Milkshape the shield bubble you mentioned - its ID is shown as M2_F00FB9DE, is this correct?

To re-export it, should I keep the "M2_F00FB9DE" as its group name, or should I rename it to just F00FB9DE?

Or should I call it "ShieldBubble" before exporting, and then rename it by listing it in the sur_input.ini as "ShieldBubble.sur F00FB9DE"?

There is another identical bubble, its ID is shown as M11_00001260. Is this one the base collision detection bubble?

I have tried to resize the bubbles in another simple sur I made (which actually seems to work, hits and collisions are fine! - but the bubbles are huge!!) to make them a closer fit on the sur shape that I want, but they don't work without resizing them to the cmp file with FLModel Tool. And when I do that they get distorted badly again.

You mention exporting the bubbles separately and passing them through sursplicer - would you patiently explain to me the steps to do that so I can try to replicate it?

Is there another way I can put in my own shield bubble without the SUR exporter putting in more? I'm still trying hard to understand what is going on - it's a bit hard at the moment.

My need is to make closer-fitting sur files for the large proportionally-sized ships in our mod. Using other surs and resizing just doesn't work very well at all because there are no close-fitting surs in the original game. The Enterprises for example, and the Brel, and several others - I really want to do a nice job on these and get to understand how surs work better too.

Many thanks again in advance.

Edited by - StarTrader on 8/8/2007 3:42:54 PM

Edited by - StarTrader on 8/8/2007 3:44:58 PM

Edited by - StarTrader on 8/8/2007 3:45:53 PM

Post Wed Aug 08, 2007 10:39 pm

yes i exported "F00FB9DE" - it doesn't matter what its called however, if you're going to put it through sur_splicer because the sur_splice INI file will rename it anyways. in sur_splice.ini it should be F00FB9DE *shrug* then i take that sur and i resize it to fit my already assembled and working sur_splice generated ship sur using Tony's FLModelTool. save, run sur_splice with F00FB9DE included and test - if your results are like mine wing groups etc will impact on classic solars and ships more consistently

it is a difficult subject to understand as a modder and unimaginably more so for the programmers of the exporter who figured out how to emulate the geometry well enough to get useful SURs

Post Thu Aug 09, 2007 11:06 am

A little explanation on what all that "crap" in a vanilla SUR is for, just to see if I can enlighten some of you.

A vanilla ship SUR has 3 levels of damage detection, weapon damage, collision damage & collateral damage.

<span style="text-decoration: underline">Weapon Damage</span>

This consists of a shield bubble, the ROOT, every component (wings, engines etc) and every equipment hardpoint. When weapons fire hits the shield link's SUR bubble damage is assigned through the ships SUR bubble to the shield (blue bar drops), when it hits the ROOT the overall hitpoints drop (red bar), the components lose hitpoints if they have a collision group set for them otherwise the ROOT gets it, the hardpoints pass it onto the equipment, yes I know that the equipments own SURs do that but without them level three doesn't work and damage isn't properly assigned.

<span style="text-decoration: underline">Collision Damage</span>

This consists of the second versions of the shield bubble, components and any hardpoint attached to that component, the ROOT and it's hardpoints do both weapon and collision. This works just like the weapon damage, bounce it off things and watch the bars drop.

<span style="text-decoration: underline">Collateral Damage</span>

This is a blanket effect for the components and thier hardpoints only, when damage is done to the component or a piece of equipment mounted on that component the damage is passed to everything under that blanket, in other words if your wing takes a direct hit then any guns attached to it also takes the damage and vice versa.

There is also coding somewhere that passes the damage that the components take to the ROOT, without it your red bar wouldn't have dropped even if you'd lost a wing. The bubbles in the ship SURs aren't really needed as the damage taken by the SUR for the shield_link is passed direct to the shield settings, I think they're just a fallback by DA to make sure damage was assigned right.


The SUR Splicer only does weapon damage, the only reason you don't pass through everything is down to the ROOT being dual purpose by default in FL, and any equipment that's mounted has a SUR that also stops this from happening, resizing it with FLModelTool does help (sort of) as it renames every part of the SUR as ROOT.


While the rest of you went "Huh! doesn't F&%*in' work" and stormed off in the huff a couple of us kept working with the exporter, and within a couple of months had created primitive multi component SURs. unfortunately I think I'm the only one that's kept at it.

I've created a small mod with one of my first working SURs, it's been 18 months since I last looked at the ms3d so it took a bit of finding, the model is a couple of primatives with a texture tiled onto it so don't expect anything fancy, but it does give both weapon and collision damage on all of it's components, the same very low poly model was used for the CMP & SUR.

I've used the knowledge that I've gathered about the Exporter to create this little mod, it's an update on the previous one, but this one has all 3 damage levels in it. To achieve this I've taken the old model and added 4 new meshes to it (2 gun barrels & 2 equipment blocks) and a selection of equipment hardpoints, exported a combined CMP & MAT from it then deleted the 4 new meshes and the material and exported the SUR with the hardpoints in place, this means that the hardpoint hitboxes in the SUR are in the same place as the equipment is on the CMP.

To achieve the same results with a more detailed model is very possible (I have) but the the CMP & SUR <span style="text-decoration: underline">MUST</span> be exported from different models, the model for the CMP can have a couple of thousand polys with out problems, the SUR needs a very low poly model to work right, and the part of the model that becomes the ROOT in the SUR needs to be a primative shape as any "dents" and the SUR doesn't work, I call them "dents" as I can never remember if it's a convex or concave face. This is the part that screwed everyone up in the past as they used the same model for both CMP & SUR, and as Cold_Void can probably testify to, the vast majority of the models we have available are totally useless in thier current form, to get a close fitting SUR to work for them requires them to be totally rebuilt.

**EDIT**

Isn't it amazing what you can learn when you go back to basics, I now have destructables working straight out of the Exporter. I have a SUR that has the full damage detection, but it only works at about 95%, the starboard wing (right side) comes off every time but the port wing (left side) causes a CTD, so there are still issues for Colin to work on. I can create a 60% SUR that does weapon and collision damage that allows destructables to work, even without equipment mounted this SUR will not allow parts to pass through other SURs.

Guess who's spending the weekend doing models

**shuffles off with a new headache**
**EDIT**
Removed the links as I've deleted the files

Edited by - Bejaymac on 9/1/2007 12:34:48 PM

Post Fri Aug 10, 2007 7:14 am

>Collateral Damage

>This is a blanket effect for the components and thier hardpoints only, when >damage is done to the component or a piece of equipment mounted on that >component the damage is passed to everything under that blanket, in other >words if your wing takes a direct hit then any guns attached to it also takes the >damage and vice versa.

No.
When you hit a weapon that is mounted on a wing, you ONLY hit the weapon, the wing wont get damaged, the root wont as well.
Vice versa is also wrong: If you hit a wing with a weapon attached to it, the weapon will NOT take any damage.
You are right about the damage forwarding to the root of the components, this can be disabled in the shiparch.ini (root_health_proxy = true)

Edited by - w0dk4 on 8/10/2007 8:15:02 AM

Post Sat Sep 01, 2007 11:52 am

I've had other things on my mind and forgot about this thread(models by the ton).

@ w0dk4, please enlighten me as to what those blanket component parts of a DA SUR are for then. My work with the SUR exporter has shown that those blanket parts are the only part that the exporter doesn't do right on a complex SUR, they're constructed right AFAIK but they block 99% of the damage from getting to the component and equipment parts of the SUR, passing directly to the "Root" instead. They also don't "detach" when the component has been destroyed, resulting in a good old fashioned CTD.

**shuffles off with a new headache**

Post Mon Oct 29, 2007 6:20 am

thx for the tool,
im working on a custom base and it helped a lot.

however i have 2 problems:
a) object <span style="text-decoration: underline">spin</span> in the system ini will make only the root sur work properly
seems weird, but when i remove spin all sur parts do work. (except for one but i guess its just too complex)
b) object <span style="text-decoration: underline">spin</span> is getting out of control (ex. should only spin around 1 axis but does all)

if i remember correctly i have also tested a resized vanilla sur and it made the same problem (b).
without any sur files the spin works normal.
these spinning parts are the whole concept behind the base, so i wouldnt want to miss them, but i have no idea what is the conflict with sur and spin.
so does anyone know about this or have any ideas?

Post Mon Oct 29, 2007 11:42 am

try using a different SUR mass setting? (higher) the original stations are all 1 million pounds or kilos or whatever unit its supposed to be

Post Tue Oct 30, 2007 4:05 pm

thx, i'll give it a try.
by the way, i have solved problem A like this:
made a dummy object which has no mesh but all the hardpoints of the original object, and a HpMount. i also added HpMount on the original.
then i made the real thing to equipment and connected it to the dummy,
now when it spins all sur parts register collision normal.
still going like crazy though, so i'll try the sur mass setting, think i used only a value of 10000.

Post Thu Nov 01, 2007 5:01 pm

hm, thought i have seen a post about hex editing sur mass, but cant find it.
im just too lazy to export all sur parts again. (count ~40-50)
anyways, while fixing the spin, i lost the sur functionality again.
i have experienced really weird things with surs and spin,
too weird, so now im happy just to have good sur and no spin. (even though its a very big loss)
guess i have to hope for a perfect sur exporter or some other wonder.

Post Sat Nov 10, 2007 1:40 pm

Rimshot:

Inertias in sur files:

Hex Address 44-47 = x; 48-4b = y; 4c-4f = z all floating point 4 bytes

Roleplay: - the art of self-deceipt!

Post Sat Nov 10, 2007 4:41 pm

StarTrader sure is full of surprises

Return to Freelancer General Editing Forum