Silgrad Tower from the Ashes

Full Version: Collision not exporting properly.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Sorry if this in the wrong place, but there didn't seem to be anywhere to ask modeling questions. I've already been through some of the tutorials, including
[3DS] Collision: the easy way out using gundalf's exporter
and
[3DS] How to export multiple collision meshes

As well as having successfully exported static meshes with collision previously. So please don't just go pointing toward a tutorial without actually providing some sort of explaination.

I'm using 3dsmax 8 with the 0.2.9 exporter (included screenshot of export settings (probably isn't the problem)). For whatever reason when exporting, it fails to make the collision information properly. When I look at the mesh in nifscope all the verticies in the collision mesh are cleared out to 0,0,0. As I'm trying to export two different collision meshes, I've tried both grouping (individually, and together), exporting only one (deleting the other). No matter what it seems to get broken. I've tried re-exporting meshes that I've managed to get collision working properly, and they seem to work... Until I try grouping them, then they have the same problem... I would assume this would mean something is wrong with either the mesh, or being able to group them and the exporter. However as the collision mesh is rather complicated, (and already derrived from the rest of the model (parts all attached together, verticies welded, optimized) and given havok) I don't think recreating it is particularly viable in this situation. As there are a fairly large number of people making static meshes here I'm hoping someone has some idea how this could be fixed.
If possible, can you post one of your not-working Max files in the just-before-export state? I know when I work there are several steps that I always do just before export but never save in Max. If you could save your Max file just before export and post or PM it, it might be helpful.

Thanks,
Steve
The only thing right now that comes to my mind is - have you made resetxform for both the base and collision meshes?
Quote:Originally posted by SACarrow
If possible, can you post one of your not-working Max files in the just-before-export state? I know when I work there are several steps that I always do just before export but never save in Max. If you could save your Max file just before export and post or PM it, it might be helpful.

Thanks,
Steve
I havn't really been making incremental saves in this case as each new mesh is a change to an existing one... For the purposes of walkways. I have a side portion, which is the one that works until I try grouping to get multiple collision meshes. Then I have a corner portion which is the side with a few pieces cloned, modified, and attached. In both cases, the base mesh exports correctly. I did however make the collision mesh for the corner from the completed corner (made it a seperate material, attached all pieces, welded verticies, and optimized), deleting the old collision, rather than adjusting the old collision. The .max files are over 500kb each, so I'd have to upload it to filefront or something for you to see them.

What would a resetxform accomplish? I do however have multiple edit mesh and unwrap uvw modifiers (since moving one tended to screw up or break the mapping), but don't think it's what is causing the problem
since the side portion seems to get broken just by grouping the collision within its own group, and it doesn't have quite as many.
Quote:Originally posted by Vagrant
What would a resetxform accomplish? I do however have multiple edit mesh and unwrap uvw modifiers (since moving one tended to screw up or break the mapping), but don't think it's what is causing the problem
since the side portion seems to get broken just by grouping the collision within its own group, and it doesn't have quite as many.

If you resize or move an object in 3D Studio Max - whether it's the real model or the collision mesh - you should always reset it's Xform else it won't export correctly. It will most likely get deformed. This is especially true of collision meshes. I've made it a habit of saving my max scene as a new version as my last step and then resetting the Xform of everything and turning them into editable meshes. It's just faster to always do it.

And I feel the same way as SACarrow does about posting the max scene. Before I can tell what's going wrong I need to see what the scene looks like. Just slap it up on badango or similar site, only takes a minute or two.
Quote:Originally posted by Razorwing
Quote:Originally posted by Vagrant
What would a resetxform accomplish? I do however have multiple edit mesh and unwrap uvw modifiers (since moving one tended to screw up or break the mapping), but don't think it's what is causing the problem
since the side portion seems to get broken just by grouping the collision within its own group, and it doesn't have quite as many.

If you resize or move an object in 3D Studio Max - whether it's the real model or the collision mesh - you should always reset it's Xform else it won't export correctly. It will most likely get deformed. This is especially true of collision meshes. I've made it a habit of saving my max scene as a new version as my last step and then resetting the Xform of everything and turning them into editable meshes. It's just faster to always do it.

And I feel the same way as SACarrow does about posting the max scene. Before I can tell what's going wrong I need to see what the scene looks like. Just slap it up on badango or similar site, only takes a minute or two.
Looks like that fixed it. Although I still seem to only be able to export only one set of collision meshes. I have them in individual groups, and have the collision properties set. I have the .max scene with the textures wiped (so that I don't have to include something that wasn't even right to begin with), and the xform reset in the .rar. It's a different file name, so I still have the one before resetting/clearing if needed.

Feel free to let me know if I'm doing something wrong with the collision or anything that might improve performance in game should you see anything. I understand I could probably make the arches a bit simpler on the collision, and have already with the side portions. But feel free to mention anything else that doesn't look right, or would help improve performance.
Here's what I did. First I took your Max scene as it was, with your objects as they are shown in the first list, and exported everything into the first NIF using the export settings as shown.

Then I took the two collision meshes and grouped each of them individually into a group with the same name as the original CM. That object list is also shown. Then I again exported with the same settings into the second NIF.

I took a minimalist approach to this, so I may have missed something. However the first text NIF does have one CM, while the second NIF has two CMs. Big Grin

Hope this helps,
Steve
Yeah, that seems to do it. Still need to get the collision properties right, but atleast it's exporting properly. Thanks for the help.
I can't think of much to add that SACarrow didn't mention. Big Grin

I noticed "Coll1" was set as "Heavy Stone Stairs". It should probably be "Heavy Stone".

I might have used a transparant texture instead of meshes to make the decorations in the bannister. Not primarily to save on the facecount in this case but because textures lend themselves better to perfect circles than meshes do. Saving on the facecount would be a bonus though, allowing that to be distributed on additional detail.

All in all you did a fine job.
Quote:Originally posted by Razorwing
I can't think of much to add that SACarrow didn't mention. Big Grin

I noticed "Coll1" was set as "Heavy Stone Stairs". It should probably be "Heavy Stone".
Heavy stone didn't sound right when walking on it. The top surface butts against terrain with cobblestones, and grass it just didn't sound right.

Quote:Originally posted by Razorwing
I might have used a transparant texture instead of meshes to make the decorations in the bannister. Not primarily to save on the facecount in this case but because textures lend themselves better to perfect circles than meshes do. Saving on the facecount would be a bonus though, allowing that to be distributed on additional detail.

All in all you did a fine job.
I didn't really want to do that since players would be spending most the time looking at them from angles above or below, or along side. The paper thin textured bars just didn't seem right. I might switch to a slightly more poly-friendly pattern should I need it, but as I'm mainly focusing on performance tests at this point, I would like to have a few places I can look to later to get better fps.

Right now within a 3x3 cell area I have over 600 sides (half the corner), and about 60 corners. Added to about two dozen building statics (9000+ polys each), about 50 other statics of varying complexity. and 15 NPCs with still acceptable frame rates. Given that it'll be atleast a year or two before this mod is anywhere near complete, and I'm already getting about as complex as I'll ever be, I'm optimistic.

My main concern was that as the mod would be based around entirely new meshes, while I'm using Beth statics as stand-ins, there would be a significant difference in performance. I'd thought about trying to use lofting, but not too sure how to attach more than one together, or how to make a single loft conform to a more complex shape without eventually turning it into a mesh and theoretically breaking the point of using a loft in the first place. Then again I don't understand all the logic involved.