STEAM GROUP
Blender Source Tools BleST
STEAM GROUP
Blender Source Tools BleST
232
IN-GAME
1,494
ONLINE
Founded
November 8, 2013
All Discussions > Help > Topic Details
Titanic Sep 9, 2017 @ 8:49pm
Skeleton not being exported after model pose changed
I'm trying to slightly modify an existing model by rotating some of its bones. After loading my model in Blender I went into Pose mode and rotated the bones the way I wanted. Then I went to "Modifiers" and click "Apply". Then I did "Pose -> Apply -> Apply Pose as Rest Pose". This moved all the meshes and bones to fit the pose I made. At this point everything looks perfect in Blender.

However after I exported my model as an SMD file I opened the SMD file in a text editor and saw that there was only one "nodes" and "skeleton" entry. How can I get Blender to export all the bones in my model correctly?

edit: Forgot to mention I applied the modifier after changing the pose.
Last edited by Titanic; Sep 9, 2017 @ 9:09pm
< >
Showing 1-8 of 8 comments
Zappy Sep 10, 2017 @ 12:16am 
Have you added a new armature deform modifier after applying the previous one?
Artfunkel Sep 10, 2017 @ 6:09am 
As Zappy suggests, when you applied the modifier you broke the link between the mesh and the armature. The good news is that your bone weights should still be there, so you can just create a new armature modifier, link it to the armature, and export again.
Titanic Sep 10, 2017 @ 1:36pm 
Ok, I added an armature modifier and exported, and now the "nodes" and "skeleton" sections of the SMD are correct, but the "triangles" section still only has "0" as the first entry for every triangle.

For example the first row with numbers in the "triangles" section in the original SMD starts with:

8 0.089100 -20.022499 ...

but in my new exported SMD it starts with:

0 0.089139 -7.609620 50.841610 ...


The first number is always "0" in my newly exported SMD, while it varies in the original SMD. I think the first number links the bone to the triangle. How can I get the bones to be linked to the correct triangles?
Zappy Sep 10, 2017 @ 1:41pm 
Originally posted by a clean Xbox:
- The first number is always "0" in my newly exported SMD, while it varies in the original SMD. I think the first number links the bone to the triangle. How can I get the bones to be linked to the correct triangles?
The first number isn't really that relevant, as it's only used for GoldSrc models (I think) and in case the bone links at the end of each line don't add up to 1.0 in the end (where the bone as the first number then gets used as the remainder to fill it up to 1.0, I believe). In other words, it should be fine.
Titanic Sep 10, 2017 @ 3:32pm 
Originally posted by Zappy:
Originally posted by a clean Xbox:
- The first number is always "0" in my newly exported SMD, while it varies in the original SMD. I think the first number links the bone to the triangle. How can I get the bones to be linked to the correct triangles?
The first number isn't really that relevant, as it's only used for GoldSrc models (I think) and in case the bone links at the end of each line don't add up to 1.0 in the end (where the bone as the first number then gets used as the remainder to fill it up to 1.0, I believe). In other words, it should be fine.

Ok, this time I did a simpler test by rotating only one bone, applying the modifier, applying the pose, and re-adding the modifier. Now I see the model is not rotated, but is pinched around the bone that was supposed to be rotated. I'm wondering if what I'm doing is the correct way to rotate bones in a model.
Titanic Sep 10, 2017 @ 6:25pm 
I think there might be a bug in the SMD export process, because when I export my model as an STL it looks like it does in Blender, but looks wrong when I export as SMD.

Is my assumption that an STL export should look the same as an SMD export correct? If so I'll file a bug report.
Zappy Sep 11, 2017 @ 1:35am 
Originally posted by a clean Xbox:
Ok, this time I did a simpler test by rotating only one bone, applying the modifier, applying the pose, and re-adding the modifier. Now I see the model is not rotated, but is pinched around the bone that was supposed to be rotated. -
Originally posted by a clean Xbox:
I think there might be a bug in the SMD export process, because when I export my model as an STL it looks like it does in Blender, but looks wrong when I export as SMD. -
Could you show a screenshot of that/those thing(s), please?
Titanic Sep 11, 2017 @ 1:56am 
I figured out the problem. I was trying to use jiggle bones with the model, and didn't have a jiggle bone for the highest bone in the hierarchy that I rotated. This caused that bone to not appear rotated when viewed in the Source viewer, which might be a bug in itself but I can work around it. After I added a jiggle bone for that bone in my QC file the model looked correct in the Source viewer.

Thanks for your help guys.
< >
Showing 1-8 of 8 comments
Per page: 1530 50

All Discussions > Help > Topic Details
Date Posted: Sep 9, 2017 @ 8:49pm
Posts: 8