Importing Team Fortress 2 Item Models into Blender

So maybe you, like me, are interested in making an item for Team Fortress 2. And maybe you’re new to modelling so you want to look at TF2 models in, say, Blender (though this will get you far enough if you’re using something else). With the new SteamPipe content distribution system, though, shit’s all hidden and confusing now ’cause they converted all the .gcf files into .vpk’s. Even if you’ve extracted stuff from TF2 before, maybe you’re having a hard time now. All the tutorials for how to do this are outdated and I can’t be the only dumbass who couldn’t figure this out in two minutes, so I am gonna put this here for anyone who needs it.

Step 1: If you haven’t done so already, install the Source SDK. Part of SteamPipe’s intention was to obsolesce the SDK launcher and instead, your TF2 development tools are going to be beta versions found in C:\Program Files (x86)\Steam\SteamApps\common\Team Fortress 2\bin, but you still need the SDK installed to decompile later. Hover over the Library tab, select Tools from the drop down menu, and install the Source SDK. Once it’s installed, run it once. It will take a while to copy some files. If it doesn’t, tell it to Refresh SDK Content. Once it’s done, close it.

Step 2: Go to Nem’s Tools and download GCFScrape. Even if you already have GCFScrape, go there and get the newest version. I had 1.8.2 and it wasn’t current enough even when the one out at the time of this writing was only 1.8.4. That .2 makes a difference. Once it’s downloaded, install it.

Step 3: Run it, and click the open folder. Navigate to C:\Program Files (x86)\Steam\SteamApps\common\Team Fortress 2\tf and open:

tf2_misc_dir.vpk if you’re looking for models
tf2_sound_misc_dir.vpk if you want sound effects
tf2_sound_vo_english_dir for voice clips
tf2_textures_dir for textures, I guess? It would seem the textures are separate of the models.

You always want to pick the files with the _dir in them. I let you figure out how to manage that other crap ’cause we’re talking about models here.

Step 4: Find the stuff you want, which I think you can manage on your own. When you find a thing you want, right-click all the files with the same filename (you can select multiple objects by holding down the Ctrl key as you click them) and select “Extract”. It’ll ask you where you want it and I strongly advise you to make a folder for it to keep all the files together.

Step 5: Next go to this Valve Developer Community page and download Hooch’s fixed version of the file at the bottom. Unzip it. Put the .exe in C:\Program Files (x86)\Steam\SteamApps\common\SourceSDK\bin\ep1\bin. Run it. If it gives you an error about MFC71.DLL, unzip the mfc71.rar file that was in the same folder as the .exe and drop the file enclosed in C:Program Files (x86)SteamSteamAppscommonSourceSDKbinep1bin too. Go ahead and make a shortcut to the .exe on your desktop too, that’ll save you a lot of hassle.

Step 6: Run MDLDecompiler and navigate to the folder you extracted your files from GCFScrape to. Pick a model and open its folder. Select the .mdl file. Then make a folder for your decompiled model and select it as your output location.

Step 7: I’m going to assume you have Blender installed already and it’s updated and not that antiquated shit they’re talking about on this VDC page. Download the .zip file but don’t extract it. If you have the ye olde Blender, follow their installation directions. If not, proceed here.

Step 8: Open Blender and go to File > User Preferences > Addons. At the bottom, click “Install From File”. Navigate to and select the .zip file you downloaded with the Blender Source Tools in it and click “Install from File”. It will install the entire .zip file. Then, in the Categories menu to the left in that window, select “User”. Find the Import-Export SMD/DMX Tools addon and check the box next to the picture of the stick figure flailing around. Now, go to the bottom of that window and click the Save User Settings button. That’ll make it so you don’t have to check that box every time you open Blender and want to saucemodel.

Step 9: Now when you go to File and look at the Import and Export menus, you’ll have options for a number of Source Engine file formats. Like .smd! Which is exactly what you want to import now. Go to File > Import > Source Engine and it’ll open a file browser. Navigate to the output file you selected when you were decompiling and there should be an .smd file in there. Select it.

Your TF2 model should now be there, textureless, ready to be edited.

The world is now your oyster!

I hope this tutorial helps you out, but if it doesn’t, please feel free to ask questions in the comments. I am not an expert in Blender or Source, so I can’t always help you with that, but a lot of times issues with following these directions have to do with updates to any and all of these tools. It helps immensely to have problems like that brought to my attention so I can keep this tutorial current with the tools used in it.

However! demonfox38 is working on an MVM map over at dfbuilds and they have already and will continue to post a lot of information about both Hammer and Blender that may be of interest and use to you if you have questions about what to do with this stuff once you’ve got it.

Related post

  1. NO IMAGE
  2. NO IMAGE
  3. Brookstone Axent Cat Headphone Review and Gaming Compatibility Fixes
  4. Don't Make Overkill's Mistake: The Art of the Tease
  5. Launching Games With Unusual Formats (Including DOSBox) in Steam
  6. Don't Make Overkill's Mistake: Cross-Promotions
  1. Joao 2013.08.21 8:02am

    Grettings,

    I would appreciate if you would be willing to help me out

    On the step 8 I am not finding the Import-Export SMD/DMX Tools addon, I do as you say “Navigate to the folder with the script you downloaded in the last step and select the datamodel.py file. Repeat for the io_smd_tools.py file.” I selected both datamodel.py and io_smd_tools.py and clicked the install from file.

  2. Joao 2013.08.21 8:10am

    I have tried to “install from file” the entire rip folder of the script and it worked, I will to see if the rest goes smooth…

  3. Joao 2013.08.21 8:27am

    Everything seems to be working fine.

    • DJ 2013.08.21 8:41am

      Good, I’m glad it’s working for you. Good luck with your model!

  4. keith.e.niceguy 2013.08.24 12:29pm

    Im stuck on step 6 as it wont load cause it keeps on saying “No Reference Decompile” can someone help me with this please

    • DJ 2013.08.24 9:47pm

      I will try to figure out what the problem is, but I found that I am missing my username folder and so cannot try to replicate your problem presently. I’m not sure if it’s a result of one of the newest client updates or if, because I had to reinstall Steam completely recently after the July 6th update broke all my Source games, I didn’t have the SDK reinstalled. With all the updates to the Steam client recently, especially those involving the Steam Pipe, it’s possible my tutorial may already be out of date. I am installing the SDK now, though, so I will comment again when I have further information for you.

      In the meantime, you might try googling that error with “Mdldecompiler” to see if anyone else has encountered it yet.

    • DJ 2013.08.24 10:19pm

      Okay, I figured it out. When you extract the model’s files in GCFScrape, you have to extract all of the related files, not just .mdl. Apparently, when it decompiles the model, though it only references the .mdl file as the directory, it pulls information from the other files in the process. So if you’re missing, say, the dx80.vtx, it can’t complete the decompile.

      So, for exmaple, when you’re in GCFScrape and you want to decompile the model for Spy’s Sapper, you would need not only v_sapper_spy.mdl, but also v_sapper_spy.dx80.vtx, v_sapper_spy.dx90.vtx, v_sapper_spy.sw.vtx, and v_sapper_spy.vvd. Basically, any file that has the same file name as the model you’re trying to pull. Extract those all to the same folder and then the MDL Decompiler should be able to decompile from the .mdl.

      I realize I was a bit vague about this, beyond saying that the model would have more than one file, so I will edit the tutorial to be more specific about that.

      Please let me know if this does not work for you and I will try to figure it out.

      • Carecoaxer 2014.09.11 2:26pm

        Hello.

        When i was trying to find those vtx:s, and all other stuff… i came to the conclusion that it would be easier to just decompile whole root. it might be slow but it works though.

        this guide helped me a lot, thank you.

        • DJ 2014.09.11 2:30pm

          No problem. I’m glad I could help!

  5. Vladimir Rasponov 2013.09.20 10:53am

    Dear sir, so far, things has gone well, untill I reached step 8
    I try to enable smd/dmx import-export, but everytime I try, the program crashes

    • DJ 2013.09.20 10:56am

      Haha, I’m a lady.

      I’m not at home right now, but I will try to figure out your problem this evening.

    • DJ 2013.09.24 11:45am

      Sorry for the delay.

      This Google Code snippet seems to suggest that the version of Blender can potentially be incompatible with the addon. Make sure you have the most up to date version of Blender and see if it works then.

  6. Kenny 2014.01.09 11:35am

    Hello, I just wanted to give a thank you for such wonderful instructions. I’ve been playing with Blender for quite some time and I’ve decided to finally take things seriously with it. Been studying like crazy for the last month or so and have improved a decent amount. However, I was told that I should make TF2 items that are usable in game as a good exercise to improve myself and make something noteworthy. I have literally spent the last 3 days constantly searching for hours on end on how to get files in to Blender so that I can start editing them and get them in the game. Finally, I have found that guide to help me get started. Thank you very much! Now I just have to start making stuff and figure out how to get it in the game… Back to work for me then.

    • DJ 2014.01.09 11:38am

      😀 Awesome! I’m glad I could help you out!

  7. Joe 2014.01.11 7:54pm

    On step 8 when you say to “Repeat for the io_smd_tools.py file,” where is the io_smd_tools.py (what is it? where do I/or havi I gotten it from?)Also, where is the “Categories menu to the left?” To the left of what? Is it a tab? Responses are appreciated.

    • DJ 2014.01.13 9:38am

      Hmm! When I wrote this tutorial originally, one need to extract the zip file with the Blender Source Tools in it and import both the files individually. Now it seems Blender will just let you install the whole .zip file itself. I will rewrite the tutorial to reflect this, but basically all you have to do is import that .zip file and then check the box with the stick figure next to it.

      The Categories menu is on the lefthand side of the Blender User Preferences menu. Here’s a picture with the User cat highlighted. Clicking “User” there just narrows all the addons down to just the ones you installed yourself so you don’t have to scroll through the whole list.

  8. VeryOldYoda 2014.03.16 9:04pm

    Hey Dj On Step 5

    When you are supposed to place the MDL compiler in C:Program Files (x86)Steamsteamapps***user_name*** My source sdk file is not their I Have installed it from library/tools/Source Sdk but it is still not their, wrong download? Pls Help, If so Where is the correct download?

    PS: Im Am Very new To 3d modeling/Community Item making and I have a feeling the Anwser is very obvious. 😛

    • DJ 2014.03.17 3:23pm

      Looks like Valve is switching things around again. The Source SDK now installs in the common folder, not your user folder. So the path is C:Program FilesSteamSteamAppscommonSourceSDKbinep1bin.

      Thanks for asking, though. I’ll update my tutorial to reflect this change they’ve made.

      • VeryOldYoda 2014.03.17 8:09pm

        Thanks Dude I appreciate it, your response was fast and helpful Thanks!

      • VeryOldYoda 2014.03.17 8:22pm

        One More Question,I do not have an episode 1 folder in my FilesSteamSteamAppscommonSourceSDKbinep1bin.

        Sorry to bother you

        Thanks for the help
        I own Hl2 ep 1 if that is the problem.

        • VeryOldYoda 2014.03.17 8:23pm

          NEVER MIND I was looking in the source sdk base no the Source Sdk Sorry And Thanks for all the help.

          • DJ 2014.03.17 8:26pm

            😀 No problem, Yoda. Good luck on your project!

  9. K39 2014.05.02 10:06am

    hey,I got to step 6,and then when I decompile,the program stops working
    please help

    • DJ 2014.05.02 1:30pm

      When you say it stops working, what does it do? Does it say it’s not responding? Closes itself out? Just acts like it’s thinking forever? Freezes up?

  10. Scout’s Lover 2014.05.16 12:59am

    How would I get the Female Classes to work because they don’t have .mdl files

    • DJ 2014.05.16 9:12am

      I haven’t done any work with reskinned models so it might be a better idea to ask the developer of the model, but I downloaded ChemicalAlia’s Female Medic model just to see and it does include an .mdl. If hers are the ones you’re using, the .mdl is located under the modelsplayer subdirectory of the folder.

  11. Infu 2014.06.26 6:47am

    Hi, and thank you for the tutorial.

    It seems like I have run into a problem. When I import v_scattergun_scout.dmx.smd, which is the scattergun, it appears as the default stock block, instead of an untextured scattergun. Help please?

    • DJ 2014.06.26 9:50pm

      I am extremely busy this weekend, but I will try to look into this on Monday evening. I wish I could be more prompt, but please feel free to ask other sources in the meantime. Facepunch might be able to help, but make sure to read their forum rules before asking for help.

  12. Zac 2014.11.18 7:39pm

    For some reason, in the common>Team Fortress 2>bin there is no Library tab

    • Zac 2014.11.18 7:43pm

      Ah, nevermind! It’s on steam! Not in the bin folder

  13. Alex 2014.12.12 2:27pm

    Thanks again for this tutorial!

    I’m on step 9 and when I try to unload the scout, his bones just show. Can you please tell me what I did wrong?

    • DJ 2014.12.12 8:28pm

      Sorry, I’m afraid I don’t know much about the character models. This is mostly for the purpose of getting weapons and hats in. The people at Facepunch might be able to help you though.

  14. Squiggleberry 2015.03.21 9:21pm

    Hi, I got everything worked out but i was wondering how to add colors or textures. I’m not sure if you have another tutorial on that but if you please reply me a link. Thank you!

    • DJ 2015.03.22 4:02am

      No, I’m sorry. This is pretty much all I know about it. There should be a ton of other resources available about that though. Facepunch, etc.

  15. SamurEYE 2015.05.17 11:23am

    I’m stuck in step 5. When I’m supposed to unzip the .exe file to C:Program Files (x86)SteamSteamAppscommonSourceSDKbinep1bin I can’t find find SourceSDK folder, only Team Fortress 2, SteamVr and the rest of my games, but no SourceSKD. How can I find it?

    • DJ 2015.05.17 12:02pm

      You need to install the Source SDK from the Tools section in your library if you haven’t already.

      • SamurEYE 2015.05.18 9:40am

        Thanks!

        • DJ 2015.05.18 9:46am

          No problem! Good luck!

  16. Richie 2015.09.27 1:13pm

    I’m stuck on steps 8 and 9. I preform step 8 exactly, but there’s no extra options in the import.

  17. DJ 2015.09.27 3:58pm

    After you hit Save User Settings and close the Preferences windows, you’re going to File > Import, right?

    There should now only be one extra option, probably at the bottom of that list, that says Source Engine (.smd, .vta, .dmx, .qc). Is that present?

  18. Scout The Runner 2016.02.08 3:56am

    Thanks for this. im trying to import scout’s scatter to make a 3d version to 3d printers, and this tutorial helped me a lot! but im so dumb, waited for 8 hours to download the wrong file, i downloaded source filmmaker instead of source sdk, source filmmaker have 8gb, and source sdk 500mb. now i figured out why i wasnt going through step 5 xD

  19. ShinjiteFlorana 2016.04.19 10:10pm

    Hey there! Thank you so much for the tutorial, very helpful! Question, though: This may be out of your expertise, but do you know if it’s at all possible to pose a model (eg with item, in stance) in say SFM or something, export that file in a a way that this process will also work?

    • DJ 2016.04.20 12:51pm

      Sorry, I don’t know for sure. My gut instinct is to say that it’s not because as far as I recall from my brief playing with it, SFM is not meant to export model poses.

      I’m not sure about importing models (I only ever tried to do it with items because I had meant to try making an item once upon a time), but if, when you import the model, it also contains its skeletal mesh, you should be able to pose it in Blender. However, because the item is its own separate model, you would have to import it separately and add it to the scene.

      I think. All of this is theoretical.

HELLO

Recently

August 2017
S M T W T F S
« Jul    
 12345
6789101112
13141516171819
20212223242526
2728293031  

Twitter

Instagram

 "What's the ocassion?" "Just 'cause."  #WitteMuseum teaches you to get jiggy with it.
 Simon and I made breakfast. He made the waffles and eggs and I made the bacon.  How cool! My order of "The Art of the Teese: From A to Z" was delayed so @ditavonteese sent an autographed photo along with it. Thank you, Dita!

Tumblr

PROCESSING