STEAM GROUP
Blender Source Tools BleST
STEAM GROUP
Blender Source Tools BleST
401
IN-GAME
2,201
ONLINE
Founded
November 8, 2013
All Discussions > Help > Topic Details
44 Colt Jun 27, 2018 @ 8:04am
Axis of rotation in mdl different compared to blender
I'm making a super mario character with a spinning propeller on his head:
https://imgur.com/sAEBVzs


the propeller itself is basically centered on the character's head, and it rotates about that point in blender (rotating about the z axis).

But in the model file (imgur file above) the axis of rotation of the propeller is different (the angle is not different, just the centre of rotation).

Armature is torso bone and propeller bone, which is parented to torso bone.
propeller parented to propeller bone, everything else is parented to torso bone.
I did LocRot in blender animations.




My qc file is here:

$scale 360

$modelname "flyboy/flyboy.mdl"


$cdmaterials "models/flyboy"


$body mybody "flyboy.smd"


$sequence idle "flyboy" loop fps 1

$sequence flying "flying_001" loop fps 30

Can someone help?
Thanks.

Originally posted by Zappy:
I downloaded the compiled Source model and checked it in Source Filmmaker, and yes, it seems wrong. Then I downloaded the Blender session, copied your QC file, loaded the Blender session, exported a mesh DMX (and changed the QC to load that), and compiled the model, and nothing seemed wrong.

However... You have "$scale 360" in your QC file. It's much better to do the scaling within a 3D model editor instead (so you scale it up to 360x scale in Blender and remove the $Scale line from the QC file). While I haven't tested doing so, I assume that doing that will make the model end up as you want it to, even if you do SMD exports.
< >
Showing 1-9 of 9 comments
Zappy Jun 27, 2018 @ 8:36am 
Please show a screenshot where the propeller bone's axis is visible in Blender, and another where it's visible in Source.
44 Colt Jun 27, 2018 @ 10:42am 
Bone axis in source mid animation:
https://imgur.com/AtjvDgF

Bone axis in source in idle sequence:
https://imgur.com/vAYArgT

Bone axis in blender:
https://imgur.com/gvdKY5u

I'm not sure what to make of these, the bone axis seems to be the same but the propeller mesh is clearly not rotating about the centre part.
Zappy Jun 27, 2018 @ 11:20am 
Does this issue also happen in Blender? And whether or not it does, please upload the Blender session and compiled Source model somewhere for us to view ourselves.
44 Colt Jun 27, 2018 @ 11:35am 
It doesn't happen in blender no. Here are some the drop box files, thanks.

blender file:
https://www.dropbox.com/s/vjjohtxp7s1cgne/fly_boy.blend?dl=0


compiled source file: https://www.dropbox.com/sh/h9a3l4avhuquo95/AABBO5hOvZd127yrprTpD4hXa?dl=0


Last edited by 44 Colt; Jun 27, 2018 @ 11:36am
The author of this thread has indicated that this post answers the original topic.
Zappy Jun 27, 2018 @ 12:38pm 
I downloaded the compiled Source model and checked it in Source Filmmaker, and yes, it seems wrong. Then I downloaded the Blender session, copied your QC file, loaded the Blender session, exported a mesh DMX (and changed the QC to load that), and compiled the model, and nothing seemed wrong.

However... You have "$scale 360" in your QC file. It's much better to do the scaling within a 3D model editor instead (so you scale it up to 360x scale in Blender and remove the $Scale line from the QC file). While I haven't tested doing so, I assume that doing that will make the model end up as you want it to, even if you do SMD exports.
Artfunkel Jun 27, 2018 @ 12:54pm 
This seems to be happening due to floating point rounding errors. These are large enough to be noticeable because you have an insane scene setup: your armature is scaled to 0.2, and then you scale the whole model by 360 in the QC file. You also have the origins of each of your meshes miles away from the geometry.

Once I brought everything within normal tolerances the problem went away.
Zappy Jun 27, 2018 @ 1:03pm 
Originally posted by Artfunkel:
Once I brought everything within normal tolerances the problem went away.
Speaking of problems, when I exported a mesh DMX from that Blender session, the Blender Source Tools gave 5 or 6 warnings about there being multiple armatures... even though there only seems to be a single armature. Do you know why that is? (I do apologize for asking about an unrelated issue here, but I have never had that error myself, and I don't want to create a bug report about someone else's Blender session.)
Artfunkel Jun 27, 2018 @ 1:05pm 
It's a bug. I've fixed it locally but it's not worth making a new release for.
44 Colt Jun 27, 2018 @ 1:42pm 
Yes, scaling it in blender instead of the qc file fixed the issue. Thanks.
< >
Showing 1-9 of 9 comments
Per page: 1530 50

All Discussions > Help > Topic Details
Date Posted: Jun 27, 2018 @ 8:04am
Posts: 9