Jump to content

Home

Merging Models (so to speak)


Recommended Posts

Posts from an almost forgotten thread on how to Merge Models... discussion may be carried on in the original thread. You all can thank oldflash for finding this. ;) -RH

 

Is it at all possible to "merge" a model? Like lets say I want to replace a the light armor arms with heavy armor arms (not really doing this but just an example). Can it be done by simply having the two model meshes on top of each other and then deleting the unnecceasry parts? I figure there is more to it since the result would be that the model would be missing arms. I'm just curious to know how would one go about this. Like would I simply press the Attach button and attach it to the torso? I'm sure there is more to it then that...

Link to comment
Share on other sites

Hi Jolly Boots....

 

Yes you can merge meshes from different files, at least it works with underwear models, what I usually do is open the body model I want, import the mesh part I need, with the body model selected I attach the mesh part, then delete the unwanted parts. The only problem is that you will need to fix some bone weights, and the smooth groups doesn't work with Mdlops....

Link to comment
Share on other sites

Hi Jolly Boots....

 

Yes you can merge meshes from different files, at least it works with underwear models, what I usually do is open the body model I want, import the mesh part I need, with the body model selected I attach the mesh part, then delete the unwanted parts. The only problem is that you will need to fix some bone weights, and the smooth groups doesn't work with Mdlops....

Do you think you can go into depth with the bone weights? Since thats basically what I was asking how to do in the first place. :p

 

You see, what I'm doing is something I brought up some time ago. I'm going to make Attons vest removable and Miras jacket removable. So I figured I would switch Attons torso with the underwear model torso and Miras arms and torso with the dancer model torso (the only other model with the same cleavage) and underwear model arms. The models in the end, will be replacing unused KOTOR I models and take over the Clothing item while the regular ones with vest and jacket will remain the specialized clothes.

Link to comment
Share on other sites

Yes I can, but before fixing the bone weights you need have the model done, because if you you need add or remove vertex, GMax will recalculate the bone weights and change it, messing it again.

 

I did the same thing you wanna do with Mira and Atton to Carth, I remodeled his underwear body model and attached to it his pants, boots and Canderous belt, and it is working fine :D, the only problem is that I have this seam at the back of his arms because of Mdlops.

 

Once I get the model done I do a kind of animation.... select each bone, rotate it with the local in the reference system coordinate, and add keys for it, for example, I select the arm bone set a key at frame 1, rotate it to make the arm goes down set another key at frame 4, and then I copy the first key at frame 7. If you play the animation it will lower the arm and returns it to the original position...I do it for all his bones, at different frames, doing most of the movements the body parts would do, this way I can see where the deformation is working or not, once I find a vertex the deformation doesn't look good I change the weight bone for that vertex...

 

I could go deeper on the explanation, but don't know how much you have done already....and it is much easier to understand while you work on it....

 

So I guess the first thing is getting your model done and test it in the game to see if there is some mesh problems, and spot where the bones are not working right.... then you could start fixing the bones weights.

 

That is it for now...

Kha

Link to comment
Share on other sites

Hm. I'm going to post screens and steps to make sure I did the model right.

15xl.th.jpg

Import the first model (underwear model).

25wt.th.jpg

Go into editable mesh mode on the torso.

36ex1.th.jpg

Select the upperbody mesh and detach it from the lower body.

47gq.th.jpg

53qj.th.jpg

Select everything else except fort the part needed (upperbody mesh) and delete it.

65or.th.jpg

Now importing the Atton model so it's basically on top.

77pb.th.jpg

Select the upperboady like with the underwear mesh and detach it.

80hr.th.jpg

Attach underwear torso with Atton legs so it's one big mesh.

96az.th.jpg

Now we come to the part where I am. I'm VERY ignorant on this so forgive me. The narrow white in the blue area is the bone, correct? Also, I'm not sure what you mean with "local in the reference system coordinate..."

Link to comment
Share on other sites

I did the same thing you wanna do with Mira and Atton to Carth, I remodeled his underwear body model and attached to it his pants, boots and Canderous belt, and it is working fine :D, the only problem is that I have this seam at the back of his arms because of Mdlops.

That Carth model looks good. I personally would want a vest or something on him though, topless Carth running around is my idea of a smart guy. Also seeing the Carth clothing model is in K2 any chance or trying to do the same thing for K2 (without porting over anything that isnt in K2 already though).

Link to comment
Share on other sites

Thanks Jeckel,

 

This model is not to make Carth look smart, but yummy :drool1: !! Anyway, I'm working on a mod to give Carth different cloths and underwear for Kotor I and II.

 

___

 

Hi Jolly, I'm following you here....

 

I would do a few different steps from you...

 

1. Once you have the upper body mesh... I would delete the skin modifier using the trash can in the modifier list with the skin modifier selected, because Atton's bone will mess with the mesh once it is imported to the other file anyway, and then I would save this file:

khafig016ju.th.jpg

 

2. Reset Gmax and import Atton model, it is not a good idea use the same file because it will import the bones of the underwear model and Atton body model. Now I select the Torso_geo, RArm_Geo, LArm_Geo, JacketFlapNew and ShirtFlapNew, hide everything else and do a Selection Set with those meshes (select everything and give it a name, for example cloths) to make the selection of these meshes easier, if you want you can make selections for bones and another for helpers it is a good idea... if you don't get it take a look in this Uvmap tutorial I've done for a friend.

khafig022xa.th.jpg

 

 

3. Now using File->Merge the file with the underwear mesh and select the torso.

khafig038by.th.jpg

 

4. Select the Torso_Geo, with editable mesh highlighted in the modifier list select element, enable the attach button and click the underwear mesh.

khafig040xu.th.jpg

 

5. Torso_geo and underwear is one big mesh now.... unhide all the bones and change the system coordinate from view to local, because I want the bones to rotate using their axis and not the viewport axis.

khafig054lg.jpg

 

 

6. Select all the bones and press CTRL X to make them a little transparent, let's see if the bones are still affecting the mesh...select the bone from the torso,torsoUpr_g, and rotate it around the y axis...you see that the jacket moves but not the underwear mesh... we need add the bone weights for the underwear vertices, press CTRL Z to undo the rotation.

khafig076oe.th.jpg

 

7. Let's delete Atton's shirt to see his underwear and then we can fix the bone weights...with editable mesh enabled, we highlight element and select all parts of his shirt and delete it, we hide the object ShirtFlapNew too. But before going on it is a good idea model the mesh the way you want it, export it to the game to see if it is at least working without any crash, and then, when all the modeling and texture painting is done we can fix the bones weight.

khafig081nh.th.jpg

 

continue....

Link to comment
Share on other sites

8. This is how you can change the bone weights...with the body mesh selected we enable the skin modfier and highlight envelope, in the modifier parameters we will use the bone list, the Abs. Effect in the Weight Properties, and check the Vertices box in the Filters.

khafig093lv.th.jpg

 

9. When you select a bone in the bone list, some vertices of the mesh is shown in color, this color shows the weight of the selected bone on the vertex, each bone is showed in the mesh as a red line when selected and black line when deselected. The vertex color goes from red (100% weight) to blue (1%) and no color at all (0%). If you checked vertex in the filters, you can select the vertices and they will be shown with a white square around it.

khafig109ce.th.jpg

 

10.To see the bone weight value of one vertex you select the vertex and see the number in the Abs. Effect box, it goes from 0 to 1.000, if you select more than one vertex and they have different values the box will be empty, to give it a value you just need to change the number, and the color of the vertex and the color of the faces around it will change too.

khafig111rx.th.jpg

 

11. For me the best way to see if the bone's weight is working or not is doing some kind of animation (this animation will not be used by the game)...to do that I hide everything except the bones, then I enable the Animate button and the key button in the bottom panel. With one of the solid bones selected, the bone of the leg for example, I put the time slider to frame 5 and rotate the bone leg 60 degree around the y axis. You will see that a blue key is created at frame 0 and another at frame 5, if you move the time slider you will see the leg bone going up.

khafig124rf.th.jpg

 

12. After this kind of moviment it is a good idea to put it back to the original position... then I go to frame 10 and copy the key at frame 0, hold the SHIFT key while moving the key from frame 0 to 10.

khafig136tj.th.jpg

 

13. I do this for all the possible movement of the body, moving the respective bone around all the possible axis.... when it is done I disable the animation button, hide the bones and unhide my body mesh. Now moving the time slider we can see the mesh deformation for each moviment... here we have a big hole in the mesh while the leg goes up....

khafig148ic.th.jpg

 

14. To fix that we select the Skin modifier, highlight envelop and select the bone of the leg in the bone list, select the vertex that is not in the place it should and change its value in the abs. effect, the vertex will change its color and go to the position indicated by the value you typed. It is a tedious work...but give nice results.

khafig152kd.th.jpg

 

I've written too much for now, sorry for misspelings.... if you have any further questions let me know..

Good luck!

Kha

Link to comment
Share on other sites

Hi Jolly,

 

I don't import the animations from the game... what I do here is create some movements using the animation tools from gmax to make it easier to see the deformations.

 

It would be much easier if there was a way to import the animations from the game, but if I'm not mistaken the animation from some npcs are stored in another model file...I don't know if it could be imported and used somehow.

Link to comment
Share on other sites

This is good to know the game didn't crash... now it is just model and adjust the bone weights....

 

The flaps from the shirt and jacket have a flex modifier that mdlops can not work with, or you delete it or remove the flex modifier from it (never tried though), thats why we can not use mdlops for head models, most of them have flex modifier on hair meshes.

 

The torso you need give some bone weights for it vertices, otherwise its vertices goes to the floor in the game.

Link to comment
Share on other sites

Unfortunately not, there is something in the head model that when you change the number of vertices of the file things get screwed up when you import through MDLops in the game.

 

When I merged the hair from another character the mouth and nose of the face got deformed, and the head was placed in the wrong position, when I removed a few vertices, deleted some hair objects, or removed the flex modifier from the hair object I just got the head in the wrong position.

Link to comment
Share on other sites

If the entire torso vanished... then there is something wrong....did you followed all the steps I've written here? Because mine is working....I have Atton's body and the underwear mesh I've merged using the texture from his jacket....

khafig165im.th.jpg

Link to comment
Share on other sites

Well, the torso now appears. BUT...there are a few parts that need to be trimmed down and I forgot to remove the jacket flaps. The arms probably need to be lowered with the rest of the body as well. Finally, the new torso does not move with the rest of the body.

 

almost19vs.th.jpg

almost28vs.th.jpg

almost30zw.th.jpg

Link to comment
Share on other sites

Yea... that's what I've done here.... I selected the TorsoUpr_g bone and assigned the vertices of the upper torso to 1.0 (red), selected the torso_g bone and assigned the vertices of the middle torso to 1.0, and did the same with the pelvis_g bone and the bottom vertices of the torso...

khafig178vr.th.jpg

 

In your picture it appears the torso is not in the center of the body... perhaps that is why the arms appear misplaced. Remember that it is not a good idea move the bones, because if you do its rotation center will stay in the same place, so the body movement won't look good. You will need to model the torso to fit the arms position.

Link to comment
Share on other sites

Ooh. I almost got it. The only problem is that I'm missing the shoulder and the belt area (and the hands are misplaced a little from moving them to be more in line.) But nothing I can't fix. :D

 

Thank you so much, Kha. You really did help me when I didn't do anything to deserve it. I owe you one (actually I owe you ALOT). And of course thanks for putting up with me. Hope I wasn't too much of a pain.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...