[page=Introduction]
Introduction
Seven steps to lead you from Texturing Noob to Texturing Novice, written in Plain English. This will show you have to import a basic, basic texture into any source game. Will it be the first step on your road to texturing greatness?
What you do need to know
This isn't a graphics tutorial, so I have to assume you have some knowledge in actually creating the image itself.
[page=The Seven Steps]
Seven Steps
- make your texture, whatever it is.
- ensure that its dimensions are a power of 2. this means either 2, 4, 8, 16, 32, 128, 256 etc etc... you could, for example have 16x16, 256x256, 32x1024 etc... save your texture as a TGA file (24 bit, RLE if available).
- copy your TGA into the following folder:
c:/steam/steamapps/[username]/[gamedir]/materialsrc
or
c:/steam/steamapps/[mod dir]/materialsrc - go to your c:/steam/steamapps/[user name]/source_sdk/bin folder and make a shortcut on your desktop for an exe you will find in the bin folder called program called vtex
- now drag the TGA onto the shortcut, a dos-style window sill come up and flash some text at you.
- okay, if all went well, you should now find a new VTF file in
c:/steam/steamapps/sourcemods/[username]/[gamedir]/materials
or
c:/steam/steamapps/[mod dir]/materials
if your TGA was called elephant.tga, then the VTF will be called elephant.vtf - the final step is to create the VMT file. the VMT file is a text file which describes the details of a texture, such as what its made of (wood, metal etc), specularity and normal maps. however, this is a barebones sample vmt file that will simply give you and opaque lightmapped texture (assuming we're still making the elephant texture)
"lightmappedgeneric" { "$baseTexture" "maps/elephant" }
you can just copy paste that into notepad and save as elephant.vtf. (make sure click on the drop down under tha place where you type the filename in and choose "all files" and not "text file" because if you dont notepad will automatically put a .txt at the end of the filename (giving you elphant.vmt.txt, which would be Bad)
[page=Conclusion]
Conclusion
That's it. If you have problems, please post a comment.
The code for the VMT is displaying wrong. Not sure why.
Heres the correct code:
"lightmappedgeneric"
{
"$baseTexture" "maps/elephant"
}
This method is obsolete now, since we have nemesis VTF plugin for phtoshop. The only part needed is about creating the VMT, the rest is not used anymore.
Good point, baRRaKID
^_^;
anyways, to make up for my stupidly, heres some hand links:
VTFLib
Photoshop 6+ VTF Plugin
There seem to be an error on the last line of step 2...
You open up by telling about the power of two, and then you say you can have 32x1024 textures? Not possible.
actually, its only each individual dimension that needs to be a power of two. so 16x8, 32x64 128x2048 are all valid. have a look through the hammer textures list and you'll see many like this
Heh, Barrakid, if only that smiley was on moddb...... :P
Anyway, 3 year old tut but don't care, just want to say you might want to point out this is for brush textures not model textures...ie, lightmappedgeneric over vertexlitgeneric.
do you have to save the .vmt as .vtf or .vmt?