Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
Links restored. I copy/pasted this from Facepunch and that forum shortens links, so that;s what happend.
I've checked the compile log and it mentions this:
Found 1 preexisting sequences.
bones 1248 bytes (2)
animation x y ips angle
@open 0.00 0.00 : 0.00 ( 90.00) 1.0
As you can see it somehow sets the angle to 90 degrees, but I never specified it to do so. Nor can I find a place in Blender where this can be altered..
Here's the QC:
$modelname "dome\dome.mdl"
$cdmaterials "models\dome"
$scale 500.0
$surfaceprop "metal"
$body "Body" "pivot.smd"
$body "Body1" "high.smd"
$body "Body2" "low.smd"
$body "Body3" "main.smd"
$sequence "open" "anims\open.smd" fps 30
$collisionmodel "low.smd"
{
$mass 40
}
I've also tried to compile with DMX, but that creates the same results.
Turning them all into 1 group would then force me to animate the model by vertexes, right?
version 1
nodes
0 "blender_implicit" -1
1 "Bone" -1
end
skeleton
time 0
0 0 0 0 0 0 0
1 0.000000 0.000000 0.000000 1.570796 -0.000000 0.000000
time 1
0 0 0 0 0 0 0
1 0.000000 0.000000 0.000000 1.570796 -0.000000 0.000000
time 2
0 0 0 0 0 0 0
1 0.000000 0.000000 0.000000 1.567642 -0.000000 0.000000
..
up to frame 30:
time 30
0 0 0 0 0 0 0
1 0.000000 0.000000 0.000000 0.364866 -0.000000 0.000000
Here's the syntax from Valve:
<int|bone ID> <float|PosX PosY PosZ> <float|RotX RotY RotZ>
So, as you can see, it rotates along the X-axis (as it should, same in Blender). But nowhere it's specifying the initial rotated position. I guess that rules out the problem of the animation itself and that should lead me to the positions of the bones. I'm going to dig into that some more, to see if I can find that rotation parameter somewhere.
It seems that the StudioMDL is turning animations to 90 degrees by default and I had no way of changing that whatsoever.
So I created an amature (skeleton) with 2 bones. Bone2 is my pivot point of the dome, so I need that to be at the origin of the mesh (0,0,0). Bone1 was placed somewhere straight under the origin of the mesh. I parented the static parts of the mesh to Bone1 and the moving parts to Bone2*. In this .blend file I created the idle animation (action is named 'idle). I created a keyframe1 with LocRot (that's what the SMD exports it to) and a keyframe 30. Then export the animation and the meshes to SMD.
I find the NLA-editor a very rigid tool and I couldn't get it to have multiple actions within one armature, so I just saved it to a seperate Blender file and animated bone 2 there. I named that action 'open' and exported just that (no need to export the meshes again).
So, now the model and it's animations are back in line with eachother. I still find it quite odd why StudioMDL sets 90 degrees rotation on default.. hopefully someone can shed some light on that.
*according the the first instruction (Bone Parent) here:
https://developer.valvesoftware.com/wiki/Animation_in_Blender
Make sure your animation is on keyframe 1 before you export to SMD. If you export it while having the last keyframe on the screen, the animation will start from that position.
The solution you've come up with is an overcomplicated way to achieve the same effect as grouping.
Do you know a way how to have multple actions in Blender for one armature?
Multiple actions for one Armature is fully supported but the UI for it is very awkward. I added a selection widget to make switching easier to Scene Properties > Source Engine Exportables.