Gordon Freeman is back! Half-Life 2 picks up some time after the original Half-Life left off, with Gordon Freeman working for the G-Man. Along with scientist Eli Vance and his daughter Alyx, your mission is to... well, that would be telling.
In this tutorial, you will learn how to export a model to a source mdl with CannonFodder's StudioCompiler.
Posted by PVRfrite on Apr 7th, 2008 digg this super bookmark
Intermediate Starting a mod.
So, first, most important thing you will need is StudioCompiler, which is a software that give StudioMDL and Vtex a GUI.You can download it here : Chaosincarnate.net
Once you downloaded it, you have to extract the files in :
C:/Program Files/Steam/steamapps/username/sourcesdk/bin/ep1/bin.If you have any bug, go to
C:/Program Files/Steam/steamapps/username/sourcesdk/launcher/GameInfo.txt, open it, and change ToolsAppid from 211 to -211, this should work(I hope).
So, once you done all these steps, create a shorcut of Studiocompiler on your desktop, and open it, you should have this :
This screenshot shows the model compile tab.This is the graphical interface for studioMDL.
For this tutorial I will use a table i made.(or you own model).After having exported the 3 SMD's (table_ref, table_phys, table_idle), you have to type table.mdl in the Compiled Model File. and drag the table_ref in Reference SMD.Set the Model Type to prop_static, in Sequences, check "Use reference SMD", and in collisions, drag the table_phys SMD.
you should have this :

Then, click compile!
You model is now ready for source, you can click view model in StudioCompiler to open HLMV(Half-Life Model Viewer) and see...that there are no any textures !!
So let's texture !^^
Go into the material compile tab in StudioCompiler.In shader choose the shader VertexLitGeneric if you want a model texture or LightMappedGeneric for a map texture.Same thing in Compiled Material Directory , choose materials/models for models and materials/ for map textures.
in our case we will choose VertexLitGeneric, choose material/models, and type table under Compiled material directory.Then drag your TGA textures in Materials.
You should have :

Then Click Compile.If it works, you should have this :

(Sorry for mistake)After having compiled your textures, go back to the Model Compile tab, and click again compile.Click on View Model, click File -> Load model..., and type table.mdl and there you should have your beautiful model !
Only registered members can share their thoughts. So come on! Join the Mod DB community today (totally free) and do things you never thought possible.
this is a good tut but it dosnt explain what most of us are having trouble with -- getting MAX to SMD properly, especially with animations. That is the tricky part.
This tut is marked as not related to any game, even tho it's HL2-related, is that fixable?
Nice tut, might try modeling again some time, just don't have the inspiration. Anyway, if I do, this might come in handy... :P
ummm, this is what happens when i click on the desktop shortcut, this is what i see for a spilt second, please help me!
link to what i see: I31.tinypic.com
Goldendeed, you made a mistake. In my tutorial I said to create a shorcut of StudioCompiler, not StudioMDL ^^ !
Hope you can get a good object ! If you have any bug, see the beginning of my tutorial !
I know C4menace it seems that exporting a model for HL2 from 3DS Max is hard but I haven't got it, I use XSI Mod Tool, it's free, easy, and works great for exporting/modelling.
Ok, lol im so dumb, but "C:/Program Files/Steam/steamapps/username/sourcesdk/launcher/GameInfo.txt, open it, and change ToolsAppid from 211 to -211, this should work(I hope)." what if it dosent work? I31.tinypic.com
well, first, do you have sourcesdk (downloaded)?And I found this : "http://developer.valvesoftware.com/wiki/Talk:Source_SDK_Bugs#.22Extra_App_ID_set_to_211.2C_but_no_SteamAppID.22_Error" good luck
When i try to run StudioCompiler i get a error message that says that the program cannot start because vstdlib.dll is not found. Are there a way to fix this?
Yes, since the orange box exists, the "bin" folder of sourcesdk changed.now, the real "bin" folder is in Sourcesdk folder/bin/ep1/bin <-you have to extract Studiocompiler here. Lots of people have bugs with this software but once it's installed, it's fantastic ! Good luck !^^
i downloaded and done everything right, but get an error when running it says Warning: falling back to auto detection of vproject directory. and the program just crashes. I'm also using windows vista.
Sorry, I looked everywere, i didn't found any answer
Oh everybody I found : before launching go into the directory of the game you set in source SDK and edit gameinfo.txt : add // befare ToolsAppId