View Full Version : Teddy Bear Joint Assignments?

2nd Jul 2010, 5:37 PM
Hi everybody! I'm trying to make a stuffed animal collection cloned from the teddy bear and despite assigning the correct joints to the proper vertices on the high and low mesh in MS3D, my object still disappears upon pressing "play" in Live mode. Sims2 Unimesh Bone Tool V4.09 solved the disappearing problem for my other objects, but not this one. Could it be that at this point the teddy bear is unclonable? I really don't want to settle this collection for deco-only items just yet. :cry:

3rd Jul 2010, 1:08 PM
With wat proggy you made it?
Does it include(or linked to) the original skeleton from the cloned object?(diffrent lods also use a diffrent skeleton if im correct)

3rd Jul 2010, 4:26 PM
I'm using TSR Workshop. Should I use S3PE?

3rd Jul 2010, 6:14 PM
No, just make sure you have the correct skeletons.

3rd Jul 2010, 7:34 PM
Skeletons? I guess I don't understand what you mean by that. Is it totally different from joint assignment? How would I go about checking for that?

3rd Jul 2010, 9:14 PM
eris3000, maybe you could make a clone and import it back into the game without altering anything. That way you can check wether that bear is cloneable or not before you do more work on it.
If your clone works alright, you know it is something that needs to be changed on your new toy(cute!)
As far as I can see from the pictures the assignment is OK, you did include all the joints that came with the object? Sometimes joints can have no vertices assigned, but are only used for animations etc.

4th Jul 2010, 12:20 AM
Ok, I re-imported the originals and they did not disappear. So it has to be my mesh. I don't understand what. I did export the original mesh and import it into MS, and made my new mesh from it, and assigned the joints from there. I didn't re-arrange anything and I even renamed my new group the name of the single group of the original (group_0). I've uploaded the work file if someone would like to take look.

4th Jul 2010, 1:37 PM
Sorry, cannot check your object now, but in this thread from EsmeraldaF, is information about a bed that disappears when used, this could be usefull for your disappearing toy?

4th Jul 2010, 3:06 PM
After looking at the attached wrk file I noticed a couple joints that looked to be assigned differently than the original teddy. Noticeably 0x736C32C2. In the original it appears to be assigned to the entire teddy and in yours just part of the body. The other was 0xAA25EED7. The original is the mid section included the outside seams and yours is just the very mid section.

The other thing I noticed is your joint assignments are in a different order. I have no idea at this time how to change them. Wes made a note of out order joint assignments in another thread pertaining to obj tool. He mentioned reordering them for obj tool to read them in the correct order. TSRW doesn't have the same issue is what it sounds like but I'm really not positive on that one.

I also notice there are color variations in the original teddy joints - ranging from green to red and I have no idea the significance of this.

Not sure if either of those will fix the issue, but disappearing in live is generally joints. Sorry I couldn't try fixing them, but every time I assigned vertices to a joint in MS it wiped out all the joint assignments. :/

4th Jul 2010, 5:14 PM
After looking at the attached wrk file I noticed a couple joints that looked to be assigned differently than the original teddy. Noticeably 0x736C32C2. In the original it appears to be assigned to the entire teddy and in yours just part of the body. The other was 0xAA25EED7. The original is the mid section included the outside seams and yours is just the very mid section.

Thanks for replying! And yes, 0xAA25EED7, 0x3CF1BB96, and 0xA366C63D are tricky as they are all color-coded green. In MS, to attempt to assign the right joints to the right vertices going by the orig. bear, I selected each vertices and clicked "show", under the joints tab, to see which joint is assigned there. As my mesh has a completely different shape and fewer vertices in the body area, I tried to get it as close as possible. 0xAA25EED7 has 3 joints assigned in the center of the chest area while 0xA366C63D is the left shoulder, down the back, and literally one joint in the chest, below and off to the left of the 3 assigned to 0xAA25EED7. 0x3CF1BB96 is the right hand.

As for 0x736C32C2, I'm going to go back and tack a look at that because that was tricky too. 0x736C32C2, 0x8C6BFD56 and 0x736C32C2 are all color-coded magenta. I know 0x8C6BFD56 is the mostly assigned to the left arm. So I'm going to go back and look at that, as well as this "joint order thing". That I'm not understanding. Thanks for everyone's help, I'll check back!

4th Jul 2010, 6:08 PM
Its alot easier to use WEs H his sims unimesh plugin(for MS)
Has a nice bonetool that works for sims 3 meshes also

4th Jul 2010, 6:47 PM
HugeLunatic, looking back at it, I see what you meant when you said 0x736C32C2 is assigned to the whole bear. Now the question is, how do I assign more than one joint to a vertices?

4th Jul 2010, 10:49 PM
Okay so I tried to do some reassigning and this time only tiny peace of the mesh did not disappear. I'm still not sure how to assign more than one joint to vertice though, but it looks like I'm making some progress.

4th Jul 2010, 10:53 PM
Like i said earlier, use Wes H his unimesh tool, lets you assigne 4 bones per vertex if needed.
And if you have the original in the background(list it first in the groups tab) you can copy it boneassignements on to your custom mesh. ;)
extract the plugins in your MS directory, you find the tool under the vertex menu

5th Jul 2010, 1:20 AM
Yeah I had that tool already. Just how does the layering go?

5th Jul 2010, 2:49 AM
HugeLunatic, looking back at it, I see what you meant when you said 0x736C32C2 is assigned to the whole bear. Now the question is, how do I assign more than one joint to a vertices?

A brief outline:

* Select some vertices.

* Open the BoneTool (in the Vertex menu).

There are three boxes, from top to bottom, that have the weights for the first selected vertex in them, with the joint number and the name beside each one.

For multiple assignments, the weight is the percentage that will be used for each bone. All percents should add up to 100. There are 4 rows of assignments, but there is a convention used where, on a 4th assignment, the amount assigned is the remainder of the unused weighting, so there are only three weight boxes

* You can step forward and backward through your vertex selection with some arrow buttons. You can type new values in, or use the arrows to increase or decrease the weight. You can also step through the available bones to pick one different.

* When you are through with a particular vertex, click on "commit" to keep your changes before moving to another vertex. When you are done with all, click on "Commit All" to save everything back to MilkShape.

* You will see there is another button, "Apply to All", that is the most useful part. If you select just some vertices, you can set the boxes to the values you want and click on "Apply to All" and all of the selection will be set to those values. Follow that up with a "Commit All" and you will have assigned all of your selection to your new values quickly.

* Cancel, of course, just closes the BoneTool without changing anything.

So the trick is, make the right selections and use Apply to All to be the most efficient. "Skinning", as this is called, is always a tedious part of modeling, but the quality of your final mesh will depend on doing it fairly well, because the game engine uses the weights and assignments to cause the skin to follow the bone movements. Having arm assignments on the belly, for example, will result in crazy behavior in game, but by assigning only 100% to joints will cause sharp bends, which do not look right on organic items. At a minimum, you want the vertices where the bends happen to be 50% one joint and 50% the other joint, which will add some "roundness" to the bend.

I know that "0xAA25EED7" is not a memorable joint name (it is a hash value that was calculated from a name), but it is all that is automatically available when loading a Sims 3 object mesh. If you look in MilkShape, in the joints panel, you will see that you can select a joint and see in the viewports where that is on the model, which should give you a clue what the joint is for.

Sadly, I do not have TSR Workshop installed on this machine, so I could not review your model for better advice. However, the meshing part of the model making process is generic, and the assignment process should work fine using the TSR plugins for export.

<* Wes *>

5th Jul 2010, 8:53 PM
Thanks for your reply, Wes! Now my question is this (try explain it as clear as possible):

Ok, joint 0x736C32C2 (magenta) is assigned to the entire mesh, kinda like in the background with all the other joints overlapping, so if I were to select any parts of the mesh and open up unimesh, it'll be listed in the fourth box.

Now there are these two other joints that overlap the magenta one, as well as each other; 0xAA282D40(turquoise) and 0xAA25EED7(green). Actually, green overlaps turquoise, and looking at green in unimesh, it is listed in the fourth box where magenta was, with turquoise in the first box at 100%. But, the color green is seen on top across the 3 vertices in the chest when "Draw vertices with bone color" is checked.

Now around the waist, the magenta is on top, and in unimesh, the magenta joints are in both the first and fourth box, but green and turquoise are also assigned there as well.

My confusion comes in on the part of trying to assign the joints just like that to my mesh. But when I try to overlap them, one is always dropped off somehow. I did try utilizing the other boxes in unimesh and playing around with the weights, but could never come up with the same results as the original. It really boils down to just these three joints that are giving me such a hard time.

I also posted pics of what I'm trying to say. Thanks for everyone's help!

5th Jul 2010, 9:24 PM
Is this the sims 2 bear?
Made a template that lets you convert a sims 2 mesh to sims 3, it fixes the bones.
I remember the sims 2 bear was already assigned to bones when i once converted it to a toddler suit.

5th Jul 2010, 9:52 PM
This is the sims 3 bear.

8th Jul 2010, 2:55 AM
Okay, HugeLunatic was on it. Apparently Workshop makes a big booboo of the joints. The order is completely re-arranged within the program itself. I tried exporting the meshes from s3pe and the joints, and their assignments, were in a much more logical order; I re-assigned the whole mesh according to that order in MS, exported it in the WS format, and imported it into WS. As a test, I re-exported the mesh I just imported back out of WS, and all of the joint assignments were re-arranged. This did not happen due to the format change as I tested that by re-importing the meshes (in WS format) back into MS, w/o importing into WS. The order had not changed. With the joints being out of order like that, I don't think the teddy bear will be clone-able with WS, unless it's fixed. I'm currently in the process of trying to clone it with s3pe (if I can get the darn texture part right :rolleyes: ). I'll write back to let every know if it worked or not.

8th Jul 2010, 4:21 AM
It sounds like they are not reindexing the assignments when the joint order is changed. They need to be managed like matched sets, change both or neither. But that should be transparent to a creator, a topic of interest mainly to programmers.

If you like working with TSRW, you probably ought to post the problem with the two files on their site. If you provide them with a reproducible example, they will have an easier time fixing it. The majority of the Sims 3 objects have just a single joint, and single weighted assignments. This may not really be a known issue for them.

<* Wes *>

8th Jul 2010, 4:33 AM
Their importer/exporter doesn't support more then one bone per vertex on the bear.
Prolly because there are not many objects with more then one bone per vertex.

Already mentioned(TSR) that you cant mix and match both importers as both use a diffrent joint order on import.
Same with the WSO and GEOM importer for the bodymeshes.

you can however build the files with TSRW and later update the mesh with Postal or s3PE, its how i do it most of the times.

8th Jul 2010, 4:22 PM
Yeah, I was posting back and forth, here and there at the same time because I though the problem was MS. But I've mentioned it there. Thanks for everyone's help!

edit, you can however build the files with TSRW and later update the mesh with Postal or s3PE, its how i do it most of the times.

How is that done?

I figured it out, thanks!

8th Jul 2010, 8:30 PM
I currently don't understand what the problem is with the joints in TSRW, because my multiple assignments on the teddy worked, as well this whole body joint was kept on import/export.

Did you reorder the joints within Milkshape, or did they already come in a different order than Workshop would provide it? If that's the case, I'm afraid TSRW is very strict when it comes to the ordering of groups/joints.

8th Jul 2010, 8:56 PM
when i opened the WSO file the mesh did have multiple boneassignements but i could not change them in any way.
Not with Unimesh plugin or Milkshapes bonetool.(the tools show just one bone per vertex.)

8th Jul 2010, 9:40 PM
With the Unimesh bone tool I'm able to change the joint weights, but Milkshape's 'Vertex Weight' section also fails for me. So this is rather a Milkshape bug because I can't see how this would be related to Workshop.

8th Jul 2010, 11:03 PM
Did you try to export the reassigned bear out of MS and import it back into TSRW?
Then check the boneweights on the mesh in TSRW( i didn't as i thought its a importer exporter issue)

8th Jul 2010, 11:27 PM
Teko, my original issue was before I even started using s3pe, I was assigning my mesh based off what I exported from WS. When I loaded it into the game, the objects disappeared as soon I clicked the play button in live mode.

I posted pics of how workshop ordered the joints. I changed absolutely nothing on the joints. All I did was mimic the assignments onto my mesh. When I import the mesh from s3pe the joints are in a different order as you can see in the pictures. Naming a few specific joints on the original mesh:

From WS, joint 0x736C32C2(magenta) is assigned to the entire body, joint 0x2AB90C33(yellow) is assigned to the head, joint 0xAA25EED7(green) is assigned to the chest, back, and around the waist, joint so-on and so-forth, list goes on.

From s3pe, joint 0x736C32C2(yellow) is assigned to the head, joint 0x2AB90C33(green) is assigned to the right head, joint 0xAA25EED7(drk. blue) is assigned to the left foot, joint so-on and so-forth, list goes on. Even the color codings are different.

I re-assigned my mesh according to the s3pe order and imported into WS. To see if it changed upon export from MS, I imported it back (without imported into WS first) into MS, and nothing had changed. Then I imported the mesh into WS, exported it back out of WS, imported it into MS, and that was when the assignments changed. (see picture below) I even tried to look at it in the game and it still disappeared.

I've uploaded the .package file as well as my MS backups so you can see what I see. Right now I'm trying to see if the objects works by making it with s3pe, but because I've never used until now, I have to follow the tutorials.

9th Jul 2010, 12:05 AM
Did you try to export the reassigned bear out of MS and import it back into TSRW? Then check the boneweights on the mesh in TSRW( i didn't as i thought its a importer exporter issue)

I've tested the import/export theory and nothing changed until I imported back into WS, exported from WS, and imported back into MS. The weights had not changed but the joints themselves did.

9th Jul 2010, 11:14 AM
I responded on Teko's post, srry
But did the joint order change or the names?
You might try to change the joints name to fix it but still its a error that needs to be fixed.

9th Jul 2010, 11:40 AM
I now understand why the joints were completely messed up on your second attempt. It's because S3PE provides a completely different joint order than TSRW. And as far as I know TSRW doesn't go actually after the joint name, but which position it has in the Workshop-ordering.

However the problem of course remains.

Question: Did you assign all bones to the teddy or did you intentionally leave some out? Because I'm about to blame the SKIN chunk again. :)

Edit: I just checked myself and all joints are assigned but the Vertex Weight doesn't give any results, as well the Unimesh bone tool. I need to investigate further.

I'm afraid I cannot confirm this. Look:
(This is made with TSR Workshop 2.0 (http://www.thesimsresource.com/workshop/programs/details/title/TSR%20Workshop%202.0/category/sims3/id/117/))

It's perfectly animated and doesn't disappear. :) Be extremely careful with the whole body joint.

9th Jul 2010, 3:21 PM
The whole body joint is the root bind.
If you reassigne the bear assigne it like a bodymesh and assigne the root bind as 4th bone without any weights, should do the trick

9th Jul 2010, 11:10 PM
I put the whole body joint in the 4th space, I just can't figure out what I'm doing wrong. Is 2.0 the latest version?

Okay, so when your assigning more than one joint to a vertex, what steps are you taking?

10th Jul 2010, 1:58 AM
2.0 is indeed the latest, came out yesterday.

Assigne the head to one bone(100% weight, or 99%) and put the root bind bone on the 4th spot(no weight, or just 1%)
Do the same with the arms/shoulders/legs etc etc.
then test it ingame.
If it works you can finetune the bones on the seams(were the waist meets the pelvis/ the legs meet the calves etc)

10th Jul 2010, 9:39 PM

Okay, basically what I did was took advantage of the TSRW to S3PE plug in to assign the joints, and import the mesh into WS, and behold, everything worked perfectly! Looking back on my sims 2 days, .asc format is one that handles joint well, so that may have had a lot to do with. Thanks to everyone who help me I appreciate it very much. Until next time; gonna finish the others now!

11th Jul 2010, 4:51 AM
Looking great!!

I made a attempt myself and you can do all the work with TSRW(2.0) and Wes his bonetool.
Took the medium detail meshes from the toddler and made a doll for my kid. :)


11th Jul 2010, 10:44 AM
Congrats you both! :)

Finding out about those root binds leads me to the question, if a joint can be a type of:

Transformation only
Rotation only

On the teddy bear we have the joint situation:

100% Rotation joint
Root bind Transformation joint

On doors (not sliding doors) however the following situation:

100% Rotation joint
Root bind Rotation joint

And on the door frame:

100% Transformation joint
Root bind Transformation joint

What purpose does the root bind have? :blink:

11th Jul 2010, 12:52 PM
The root bind is the main joint, all others are connected to it.
When selected the whole skeleton gets selected.
If you import a GEOM file with Wes his importer in Milkshape you can view the full skeleton and see wich bones are linked.

Strange thing is that bodymeshes imported with his importer dont have the root bind joint assigned while bodymeshes imported with the WSO importer have.
Both work fine tho :)

16th Jul 2010, 3:42 AM
Last question and I'm going to leave you all alone for now; I promise :lol: . How come my poly count nearly doubles with s3pe than with WS?

16th Jul 2010, 12:26 PM
I can not imagine your custom mesh changes polygons.
Maybe one still display the original poly's from the bear?
Were did you find its ammount of polygons?

16th Jul 2010, 7:57 PM
The polygon count is displayed under each group tab beside "mesh". The original bear is 848 vertices and 1142 faces, in WS, my mesh is 776 vertices and 948 face, but in s3pe my mesh is 1245 vertices and 948 faces. Could s3pe be counting the MLOD, MODL, MLOD_10000, and MLOD_10001 all together?

16th Jul 2010, 11:49 PM
So the polygons are the same, only the vert increased.
This could be due the exporter.
You used Wes his importer/exporter?(or has s3PE its own for Milkshape.?)
You should ask Wes this, he prolly knows why.

17th Jul 2010, 12:24 AM
I use Wes's. Thanks!

17th Jul 2010, 9:34 AM
Vertex splits.

In MilkShape (and some other programs) there is a method used that allows a vertex to have more than one UV location.

The game uses a method that requires each vertex to have only a single UV location.

The explanation of why is too long, both methods have advantages and disadvantages, but part of it goes to how DirectX was designed. So we can blame Microsoft if we want.

The exporter reconciles these differences by 'splitting' the vertices, meaning extra copies are made with one UV each. Note that you will always have to have some duplicated, because to texture properly there need to be some seams, and the splits occur where these seams are.

However, don't sweat the vertex counts. The main impact a mesh has on performance is the face count, because each face must be drawn to be visible. Vertices, while they require some amount of memory, do not render. The time required to render all the faces in a scene is what limits the frame rate.

On a side note, I dragged out my source code to look at how I wrote the Object plugins for MilkShape. Unlike the GEOM plugins, the vertex weights have been coded to single-weighting. Regardless of what you do with the BoneTool, only the first joint will be exported, always weighted at 100%.

The only reason for this was typically objects use rigid binding (fully weighted single assignments). If I understand this thread correctly, there are object meshes with multiple assignments and weightings. So I am trying to set aside some time to make those changes. More so than actually writing the code, testing requires a lot of time to do. Creating some test models is a big part of this.

If I had some testing volunteers (wink, wink, nudge, nudge) I could probably get this change cranked out sooner rather than later. It is possible to make a set of test plug-ins that will not 'overwrite' the existing ones, which is what I would propose to do, assuming I see a few hands in the audience go up.

<* Wes *>

17th Jul 2010, 11:39 PM
Wes, although I do not really understand what you will need me to do, I raise my hand to volunteer. Your tools are always so awesome and I think this will be usefull with conversions and animations too?
I guess we need to find some more objects with multiple assignments and weightings to use for testing?

18th Jul 2010, 12:40 AM
Regression testing is important, too. Meaning that ordinary single-weighted objects (that worked before) don't break because of the changes.

19th Jul 2010, 3:22 PM
Just tell me exactly what I have to do and I'll be happy to test for you. ;)

19th Jul 2010, 11:40 PM
OK, here is a modified test version of the MilkShape object plugins that will handle up to three assignments. I checked that they seem to work fine with single-assignment objects here. The added weights are managed the same way as with the GEOM plugins, but weight #4 is, at this time, disabled until I can get some verification that it works the same as the GEOM plugins (there are only three weights slots, so I am not sure).

These plugins have different names than the release V1.00 plugins, so when exporting look for "Test 1" in the name... the existing plugins wll still be there. What I want is to test your bear, and some other projects that already worked, and see that they work using these plugins. I am especially concerned that we test some projects that worked with the old ones to make sure they can be recompiled and work in-game, otherwise I will not release them until that happens. I also expect them to help on teh multi-assignments meshes, too, so we need that tested.

Let's just use this thread for test results, if it works, I will release it on the main thread for the plugins.

Thanks for the help.

<* Wes *>

Oh, yeah, just unrar the file and put the results into your MilkShape program folder, like always, These are the same as any other MS plugin, except for the name and the code tweaks.

20th Jul 2010, 2:54 AM
I tested on a painting I made using the old plugins. Everything came out fine. The one made using the standard plugins is on the right and the one made with the new plugins on the left. The catalogue shows that one is a test:


Is this what you mean by testing old projects? If so, this is working fine.

What is a multi-assignment mesh?...is that not the bear?

20th Jul 2010, 5:42 AM
Yeah. I had only seen objects with a single joint assignment per-vertex. That is usually normal, because objects are usually sharp, hard things with hinges that bend at hard angles. Sims are soft, they use multiple assignments at the bend points, so you get more organic bending (the trick is learning how to vary the weighting as you move across the transition point to get gradual, instead of sharp transitions). So the way that you make clothing meshes involves multiple assignments.
The bear is a clothing sort of item, but I had coded the Object Plugins for Maya to only use single assignments. The GEOM plugins will use single or multiple, depending on how the mesher assigns them. From all I have seen, most objects will come in with single-assignments, and stay that way unless you take some positive action (using the BoneTool) to change that.
Your test would validate that that is happening properly. One thing I don't want to do is make changes that will make using the tool the old way any different, because it is hard to get the word out. And I would not have so readily worked on this if it changed anything in the ObjTool code itself, because that would require coordinating with the Blender people also. However, the decompile/recompile copies the data as it is in the binary files, the difference was in the code that gets that data into and out of MilkShape.
I will wait for some more testers to report, especially with the multiple assignment part. But I was worried that I would break something, and while that is still a possibility, I can at least go to bed tonight knowing I didn't ruin everything (and of course the original plug-ins will still be available for everyone until this is proven out or scrapped).

Thanks for the help, oh blonde wonder. :)

<* Wes *>

20th Jul 2010, 2:17 PM
I've tested the new plug-ins on doors and dressers(2 joints), and clocks (3 joints). All worked well. :up:

20th Jul 2010, 3:09 PM
I used the pink flamingo again for a chicken, and all was good and working the same.
Just for todays smile, he kicked the chicken. ;)

20th Jul 2010, 11:31 PM
Fozzie turned out right. So far so good.

21st Jul 2010, 4:03 AM
Yay! Nice work boys and girls! :)

Since the most interested parties have the plugin (being a public beta and all) I will wait a little while to see if any party spoilers show up. Otherwise, I will repackage this a V1.01 (without the Test1 business) and put it up on the original thread message #1 spot.

I really do appreciate the help.