.obj -> .sur converter
-
Yes, that’s that what we assumed initially. But now we can assume that the geometry for the weapons etc. hardpoints in the ship .sur file is used for further calculation speedup, since just adding them without geometry results in them not being hit after all. For a full understanding you would have to look up of what data the .sur format consists of. But I guess that’s not what you want
Please understand that the converter is not final, which means for now it is written for people who understand what they do, since I was not sure how well it would work in the first place. There are still some bugs and there is still the possibility that you have to redo all your .sur files you converted.
Once the version is stable enough I will try to make it more usable for the common modder.
-
Your utility has already allowed me to make surs for some very peculiar shapes, including asteroid bases you can fly into and odd shaped ships and all the surs work fine, (have to check this turret thing as i’m curious now). So take your time, between your utility and Lancers, can make just about any sur i like, (well almost )
-
Hmm, I created a hitbox for this base using the converter.
http://i352.photobucket.com/albums/r330/SilentAssassin82/Untitled-5.png
I actually had to splice the parts together because the doors where animated. In doing this I deleted the HPIDs section of the sur and all the turrets do register hits. I dunno why but the turrets on that model are fine ingame.
-
On stations (stationary objects) the surs of the weapons itself will be used.
On ships the surs of the hardpoints will be used.
(I think) -
SilentAssassin82 wrote:
Hmm, I created a hitbox for this base using the converter.http://i352.photobucket.com/albums/r330/SilentAssassin82/Untitled-5.png
I actually had to splice the parts together because the doors where animated. In doing this I deleted the HPIDs section of the sur and all the turrets do register hits. I dunno why but the turrets on that model are fine ingame.
Interesting. So, in all my ship models, like the ISD in the video, I added HPID section for the hardpoints. I wonder if that’s the issue? Because when we made custom hitboxes, we never had to add that section before…
Interesting. How would I go about deleting this from the .sur, Schmack, to test?
And Skotty, no, I don’t believe it does work like that. The big ship in the video I made is a “station”.
-
OK, that did it. You remove the HPID section from your .sur, and the turret hitboxes magically appear.
So, with that said, what are the hardpoints that must be in the HPID to prevent crashing?
I remember HpCM01…what else was there?
-
Actually I added the option just because of crash reports. See it as a quick fix until I can include real geometry. My hope was to avoid this step, but it seems to be unavoidable
-
Damn. Just so you know, these were the hpid hardpoint sections I was adding, in general, to the hitboxes. Might have been a bit excessive.
Capital Ships
HpMount HpCockpit HpShield01 HpShield02 HpShield03 HpShield04 HpShield05 HpShield06 HpCM01 HpTractor_Source HpTractor01 HpThruster01 HpTorpedo01 HpTorpedo02 HpWeapon01 HpWeapon02 HpEngine01 HpEngine02 HpEngine03 HpEngine04 HpEngine05 HpEngine06 HpEngine07 HpEngine08 HpEngine09 HpPower01 HpPower02 HpPower03 HpTurret01 HpTurret02 HpTurret03 HpTurret04 HpTurret05 HpTurret06 HpTurret07 HpTurret08 HpTurret09 HpTurret10 HpTurret11 HpTurret12 HpTurret13 HpTurret14 HpTurret15 HpTurret16 HpTurret17 HpTurret18 HpTurret19 HpTurret20 HpTurret21 HpTurret22 HpTurret23 HpTurret24 HpTurret25 HpTurret26 HpTurret27 HpTurret28 HpTurret29 HpTurret30 HpTurret31 HpTurret32
Starfighters
HpMount HpCockpit HpShield01 HpCM01 HpTractor_Source HpThruster01 HpTorpedo01 HpTorpedo02 HpWeapon01 HpWeapon02 HpWeapon03 HpWeapon04 HpEngine01 HpEngine02 HpEngine03 HpEngine04
-
Can’t remember which hardpoint was causing crashes for Startrader but i’ve only been adding in HpThruster01, HpCM01, HpMine01 to my ships.
On bases, maybe why i’ve been able to hit my turrets, i don’t add any hardpoints at all in the sur, no problems so far.
-
I’m guessing that Schmack is right and that this really is just used to speed up calculations, whereas if you just don’t specify them the game reverts to the actual, more complex turret SURs.
Does make me wonder whether those turret SURs are used at all if you list them in the hardpoints list. Maybe they get used for calculations if and only if the simple turret is hit?
-
FriendlyFire wrote:
I’m guessing that Schmack is right and that this really is just used to speed up calculations, whereas if you just don’t specify them the game reverts to the actual, more complex turret SURs.Does make me wonder whether those turret SURs are used at all if you list them in the hardpoints list. Maybe they get used for calculations if and only if the simple turret is hit?
I think it works this way: If a beam is inside the general sur radius, the overall sur gets checked. Now, every hardpoint “rough” geometry is checked. If the beam intersects one, the actual sur of the equipment mounted at that hardpoint is checked.
So, if all your equipment is simply a sphere or a very simple geometry, I think there is basically no speed-up. But as soon as you have a lot of equipment that is rather complex, I think there can be quite a speedup.
-
Actually the speedup would be there in any case, because of the BSP tree. That’s why I think it made perfectly sense for the developers to also include simple geometry for the hardpoints. You just navigate through the tree until you hit one and after that look what is actually mounted there.
-
Adding hardpoints is a mistake, for me, I didn’t use this featur yet, but if it’s done the same thing that vanilla models, the doms you can see on station, I’m sure you can’t hit turrets on your ship. I’m probably wrong, if I’m, can you tell e where? Please, cause I’m not an expert of modding.
-
SilentAssassin82 wrote:
Hmm, I created a hitbox for this base using the converter.http://i352.photobucket.com/albums/r330/SilentAssassin82/Untitled-5.png
I actually had to splice the parts together because the doors where animated. In doing this I deleted the HPIDs section of the sur and all the turrets do register hits. I dunno why but the turrets on that model are fine ingame.
How did you “splice the parts together”? What tools / method did you use?
-
http://i352.photobucket.com/albums/r330/SilentAssassin82/Untitled-5.png
What version of HardCMP is that? I want it.
-
Looks like 1.0.0.23 to me
-
You can use this for parts with only 1 mesh in them.
http://www.gamefront.com/files/20193523/SURSpliceForOBJCon.rar
But if it’s a complex mesh like the rings in that model there, then you will have to do it by hand. That model I posted, every part except the 2 donut shaped rings where just a single mesh. So all I done was make 2 simpler SURs to start with only a single mesh and then replaced them myself with the more complex ones.
-
Nice, thanks!
-
The only difference between the two versions (sur_splice by Devast8or and SURSplice by anonymous) is the HPID tag - sur_splice always adds an empty list; SURSplice always removes it. I’ve made an update that defines the hardpoints in the input file itself. It’s not clear, but the hardpoints work per part. Not having the original example model (not that it really mattered, I guess), I didn’t update the input file, so perhaps someone would like to contribute a new example (and perhaps update the doc describing the process, if necessary). I also haven’t mentioned it in the readme, but this version determines the “bits” radius and scale values automatically (and assumes the center is already right).
-
After Sushi posted the video of his turret issues, i decided to do a test myself on a custom asteroid base model i’m using where i made a sur using the OBJ converter. No hardpoints added on this model and can confirm the turrets (standard vanilla base turrets) are taking hits with the base parts also taking seperate hits.
Certainly seems on bases at least, no hardpoints required for the sur.
Can post video if required