How to import models from Valve's Source games.

Started by Oizen, January 17, 2012, 01:25:14 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

January 17, 2012, 01:25:14 AM Last Edit: January 17, 2012, 03:59:59 AM by Oizen™

I've recently figured out how to port models from Valve's source games (Half Life, Team Fortress 2, Counter strike ect.) and a good deal of Garry's Mod model you can find.
Here's an example of a model I took out of Portal:

If you want an in-game shot check this out

Required tools:
3dsmax 2011
The SMD importer plugin. The 2010 version works with 2011.
Steam
A source game. I recommend Tf2, since its free.
SourceSDK, you can download this with steam for free if you own one of Valve's major Source Games.
GFScape Only needed if you're ripping from a game yourself.
MDLdecompiler
VTFEDIT for extracting materials.

Your favorite Hex editor.

Only read this part if you're extracting a model yourself
Sorry but you are not allowed to view spoiler contents.


next we'll need the textures, which are usually in a similar path, only in the materials folder, again export all of the files with a similar name to your model.

Sorry but you are not allowed to view spoiler contents.





This next step may already be done, but its important you check anyway.

Open your .mdl file in a hex editor and make sure the character I highlighted below is a ",". (Tf2 models are 0 by default)

Sorry but you are not allowed to view spoiler contents.



Open the mdldecompiler and input your model, and an output path, The model decomplier must be located in:
C:\Program Files (x86)\Steam\steamapps\*SteamUserName*\sourcesdk\bin\ep1\bin\ for it to work!

Sorry but you are not allowed to view spoiler contents.


Export your model, and open 3DSmax 2011, and import the ".smd" file the MDLDecompliler makes.

Sorry but you are not allowed to view spoiler contents.


Now for the textures,  Open the .vtf files with VTFedit, and go File > Export, and chose whatever image format you want. Occasionally, you have to fight with the settings on VTFedit to get the entire texture.

Sorry but you are not allowed to view spoiler contents.


Apply your texture in 3dsmax, export it as a .dae, and you're good to go.

Sorry but you are not allowed to view spoiler contents.


I'll do .bsp files (maps) some other time.

oh sweet! now we can have tf2 imports! :D
I'm back after a long while.

Quote from: Redpwnage795 on January 18, 2012, 03:33:46 AM
oh sweet! now we can have tf2 imports! :D

Indeed. I've also been experimenting with importing tf2 maps aswell.

But they're significantly larger in file size, the most promising right now is Watchtower.


Yea we really need some tf2 stages to go with the tf2 hacks. 2fort looks like a cool place to brawl on. maybe you could brawl on the RED second floor and BLU second floor. Also, i hope someone can do a model import for heavy on ganondorf.
I'm back after a long while.

Here's a good question.

If you rip a model, is it already rigged?

Most items only have one bone so basically, yeah. I also have a good question: how do you apply the textures? 3ds max or brawlbox?
I'm back after a long while.