MeshEx - .msh exportation for Gmax + XSI Mdt's

How to create models in XSI and other 3D applications and make them work in Battlefront 1 & 2. Post models, tips for application usage and share anything XSI, 3DMax, SketchUp, etc.

Moderator: Moderators

MasterSaitek009
Black Sun Slicer
Posts: 619
Joined: Wed Aug 23, 2006 4:10 pm

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by MasterSaitek009 »

We are all very grateful for your work Rep'. :D
MandeRek
Sith Master
Sith Master
Posts: 2766
Joined: Tue Oct 02, 2007 10:51 am
Projects :: Battlefront Zer0
Games I'm Playing :: SWTOR
xbox live or psn: No gamertag set
Location: Ghosting around GT
Contact:

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by MandeRek »

Fantastic Rep! You´re making something for the community which was never to be expected, and you´re saving us A LOT of money... really nice that obj is compitable as well, great work ;) :thumbs:
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by RepSharpshooter »

Well I think the obj import things work. Now just to debug the rest of it. :faint:
MandeRek
Sith Master
Sith Master
Posts: 2766
Joined: Tue Oct 02, 2007 10:51 am
Projects :: Battlefront Zer0
Games I'm Playing :: SWTOR
xbox live or psn: No gamertag set
Location: Ghosting around GT
Contact:

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by MandeRek »

Great Rep :thumbs:
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by RepSharpshooter »

Ok, a mysterious error while writing the file is now gone, and it's better code anyway. The polygon stripping algorithms are so-so. They work well if all you want to export are planes. So at this point, it can export planes. Problems arise when the triangles are turned different ways. A strip can only be in a clockwise fashion. If you have a triangle turned the other way, it makes a weird shape. Ex: a strip should look like this |\|\|\|\| Zig-zaggy. When you have the triangles turned in different directions, it goes like this: |\_|\|\_| and does weird things, which isn't good. So my option is to cut (at the points with the _) the strip up into smaller strips like |\ *cut* /| *cut* |\ *cut* /| or something like that.
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

Re: MshEx - .msh exportation for Max + XSI Mdt's

Post by RepSharpshooter »

WOOT
Image
(MshEx-ported)
For more:
Hidden/Spoiler:
Image
Image
Image
Image
Note this is JK514's skin, I just used it to test adding override textures a while back.

Problem is it seems you have to almost be a professional in modeling in order to use it. There's a certain thing you have to do for it to export the uvs correct. You have to detach the faces that have different uv mapping from the faces around them. This is hard to grasp by some people. So in the mean time, still testing it. Hopefully I'll be able to make a simpler and functional program later. (Like some people don't feel comfortable hex editing hps into it, so I guess I'll have to add a function to do so).
MandeRek
Sith Master
Sith Master
Posts: 2766
Joined: Tue Oct 02, 2007 10:51 am
Projects :: Battlefront Zer0
Games I'm Playing :: SWTOR
xbox live or psn: No gamertag set
Location: Ghosting around GT
Contact:

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by MandeRek »

Still, as i said before, this is fantastic man! You really did hell of a job on this one :D
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by RepSharpshooter »

Ok so now I'm looking into MaxScript, and how I can extend the obj format to meet my needs. I'll looking into weights, bones, and enveloping right now. I understand the WGHT chunk, not sure about the ENVL chunk as of now. The Maxscript seems straightforward, I'll have to look at some more WGHT chunks and see if everything is rigidly skinned (each vertex is only weighted to one bone). Then I'll try and mess around with some of max's skinning functions (fyi skinning = enveloping = rigging = weighting sorta). And since I'll be using a maxscript obj exporter, I can customize it for better msh export. It's a lot to look forward to, sadly not enough time to do it all as I would like.
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by AceMastermind »

Rigging
the process by which a person creates constraints and relationships
between objects that will generate controls to aid in the manipulation of a digital character

Enveloping
surrounding and closing in on (surround the skeleton with a mesh)

Skinning
the process where a model is wrapped around a skeleton.
When the skeleton moves, the model will move correspondingly.
The model effectively forms a skin over the skeleton joints.

Weighting
the process of systematically increasing the value of a particular data
element or elements so as to give that element more significance in the analysis or calculations.

I had to do it :P
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by RepSharpshooter »

Yeah Yeah :P You can go into details like that (hence the "sorta" lol).

So now I have a run-of-the-mill object exporter which I will expand. Right now it only walks objects under the rootnode which is bad, because then I need to walk down the object's children that are under the root node. Like
  • rootnode
    • object1
      • children1
      • children2
    • object2
It'll only export object1 and object2, it will neglect to go down their children. Also I need to determine what type an object is (ex if it's a null, export it like a null, if it's a bone, export it like a bone etc). Then I need to figure out how to access information in an existing skin modifier. I know the methods to get weight information out of a skin modifier, just don't know how to get information out of one already in the scene. It should just take some more time looking at maxscript to figure it out. One of the downsides of working in maxscript is that the XSI people are left out. I could check if this is compatible with Gmax, then you could always export it through that (because I really don't want to learn a new scripting language over again after this one. XSI people could still export basic props straight out of XSI using the default obj export, it just wouldn't be able to export nulls, bones, etc which is going to make up my extended obj format).
MandeRek
Sith Master
Sith Master
Posts: 2766
Joined: Tue Oct 02, 2007 10:51 am
Projects :: Battlefront Zer0
Games I'm Playing :: SWTOR
xbox live or psn: No gamertag set
Location: Ghosting around GT
Contact:

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by MandeRek »

Still, not exporting nulls and bones isn't a real problem... Gogie told me that everything can be replaced with meshes (if i understood that well) You can use meshes as bones, and, also, as nulls. Example; the assets weapons... Bones don't have an example, though tentacles get animated with meshes as bones... So this is not a worryingpoint i believe...
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by RepSharpshooter »

That's interesting :yes: I'll have to look more into that.

Well I've switched from bones and nulls to materials. I can now export all the materials in a scene, with correct texture names, diffuse colors etc. Also, I'm going to work on separating the mesh into segments depending what material they have (This will make it so you can have multiple materials applied to a single object). This is a feature I definitely need to do any other type of texturing. Unfortunately it causes headaches in nearly every section of my program, lol :faint: . Then I have to fix that weird uv problem as well.
MandeRek
Sith Master
Sith Master
Posts: 2766
Joined: Tue Oct 02, 2007 10:51 am
Projects :: Battlefront Zer0
Games I'm Playing :: SWTOR
xbox live or psn: No gamertag set
Location: Ghosting around GT
Contact:

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by MandeRek »

It sounds that you're doing a great job! My dad always says that headaches are caused by hard- and succesful work! Great job Rep! Btw, if it works; replacing bones and nulls with meshes, i would like to build a new unittemplate for you (replace bones with meshes)
Commander_Cody771
Vader's Apprentice
Posts: 1069
Joined: Thu Jun 07, 2007 5:02 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Looking for a new CPU
Contact:

Re: MeshEx - .msh exportation for Gmax + XSI Mdt's

Post by Commander_Cody771 »

Wow Rep you have REALLY made considerable progress. :thumbs:
Locked