[GUIDE] Blender, TF2 and You

Feb 18, 2009
640
629
<Post edited because I was stupid enough to not read the very first post carefully. Either way, thanks a bunch for this tutorial!>

I think it was still needed information, so I'll still add something about weapons/hats at the end of the OP. btw, don't forget to show your thanks by hitting the "thanks" button at the bottom of the post ;)
 
Feb 18, 2009
640
629
Why use a BAT file for each qc when you can use GUIstudioMDL? it's so much easier, saves time, and if the compile failed you can check the log to see what has gone. I'm sure can get a BAT file to work for all qc files you have, and maybe even stop studiomdl from closing before you can read it, but I'd personally still prefer having a GUI.
 
Feb 18, 2009
640
629
When you exported the model, did you select both the mesh and the armature? Also, I don't animate often, so I'm unaware of the bone names. Is weapon_bone present in the original model? And is everything "skinned" properly? (try moving the weapon_bone, does the mesh move with it?)
 
Feb 18, 2009
640
629
AFAIK, animation is kept in the armature, so all animations should be the same.
The scaling by 40 is necessary on all models that you import using the script in the OP. If you now want to make a view model you need to import valve's view model for the pyro's axe and delete the axe only. Place your custom model where it needs to go, and merge your model with the view model you imported. Make sure your model becomes part of the view model, not the other way around!
 

Remnic

L2: Junior Member
Jan 24, 2009
95
16
This guide is pretty useful. I just started working on a grizzled moustache for the Sniper, but that's a whole different story.
 
Feb 18, 2009
640
629
I'm not sure about your bone problem, but I can tell you that that "axis" is the mesh centre. I don't think it can be moved directly, but by moving all the verts in edit mode and moving the whole mesh back into place in object mode, has the same effect as moving the centre. Its a mistake I run into occasionally, so I'm looking to find a way of moving it directly (for more accurate positioning). As I say, I don't know about the bones though. Someone with more experience with source engine bones will have to help on that one.
 

Tehrasha

L3: Member
Nov 5, 2009
115
28
Recent news from the Blender 2.5x front...

They now have SMD Import/Export scripting for it.
Still no animation support, but at least it is being actively worked on. :)



(... now if only 3Dconnexion would update their 3D mouse driver for it ...)
 

Tehrasha

L3: Member
Nov 5, 2009
115
28
Hmm what about those who uses 2.49b? Yet I don't see any big problem with the current importer though that's available other than it rotates and scales the imported stuff down by a factor of 40.

There is a large thread over on Facepunch dealing with Blender and SMD importing/exporting. There is another script, or an edit for the existing script (I cant remember which) that fixes the 40x scaling issue.

Getting importers and exporters to fix the rotation and bone roll issues for animation is one of the hot topics in the thread.
 
Last edited:
Feb 18, 2009
640
629
Recent news from the Blender 2.5x front...

They now have SMD Import/Export scripting for it.
Still no animation support, but at least it is being actively worked on. :)

Joy of joys! I must get using this then! I've quickly updated the OP with a link to this script.
 

Tapp

L10: Glamorous Member
Jan 26, 2009
776
215
yes. select the model first, then the bones, and export as static mesh. Then export again as animated mesh, and reference that as the animation in the qc.
 

Tapp

L10: Glamorous Member
Jan 26, 2009
776
215
I'm sorry, I must admit I haven't fully gone through the process of making an animated mesh for TF2. If someone knows how what I'm saying wrong in the OP, please post it and I'll update it.

Having (somewhat) succeeded in that regard, do you want me to post what I did, with helpful screenshots and tips? Or are you already on it?
 

Urser

L1: Registered
Nov 6, 2009
14
1
I've been having trouble exporting my model using the .smd script posted in the OP. I'm also very new to modelling so I'm not entirely sure what the source of the problem is. I could export the Engineer model just fine as soon as I imported him, so I guess there must be a problem with my model (I'm making a hat by the way), but I have no idea what it is. I made sure all the normals are facing correctly, got rid of any spare/double vertices floating around, etc.

Here's the error that comes up in the console by the way:

consoleerror.png


I've spent like 2 hours Googling the damn index error, but I couldn't find an answer.

EDIT: Oh dear. Turns out I forgot to ASSIGN my material to the model. Ohwell, problem solved!
 
Last edited:

Tehrasha

L3: Member
Nov 5, 2009
115
28
Screenshot of the problem (The purple stuff is supposed to be the hat that has been rotated oddly) :

someerrorok.png

As mentioned previously...

"Getting importers and exporters to fix the rotation and bone roll issues for animation is one of the hot topics in the thread."

This goes for 2.49 as well as 2.5b scripts.
Exporting a previously imported rig (in this case, just the bip_head) currently causes no end of problems. But if you create your own rig from scratch, it should export correctly. (at least thats what the facepunch thread says)