Ads keep us online. Without them, we wouldn't exist. We don't have paywalls or sell mods - we never will. But every month we have large bills and running ads is our only way to cover them. Please consider unblocking us. Thank you from GameBanana <3

Creating Custom decals - A Tutorial for Source Engine.

Quick tutorial on making custom decals for personal tags

*Updated* -Added alternative to VTFEdit -Removed previously quoted "Creating VMTs" -Added "Creating VMTs" including advanced tips -Added many details

This tutorial will show you how to put a simple, font based, custom decal in your map using GIMP.

What is GIMP and why should I use it? GIMP is a free, open source, photo editing program. I found it a little easier for this purpose, rather than using Photoshop, because GIMP automatically does the Alpha channel. My file also came out smaller using GIMP. Currently there is not a plugin available to export .vtf files from GIMP (like you can in Photoshop), which is where VTFEdit comes in. *Notes are located at the bottom of this tutorial. If you have Adobe Photoshop, you can use the tutorial located HERE. Tools needed - GIMP - VTFEdit - Unique Font (optional) Creating the Image
  1. Run GIMP and create a new image. Make an image with the size 512x256 pixels and under Advanced Options choose Transparency for the Fill With option. *Note 1
  2. Press OK and you will have a blank image that looks like a gray checkerboard.
  3. Now we are going to enter the text you want. Select the Text tool and choose your font. For now, make the font size 100 and we'll adjust it later. (The font I'm using in my example is NOT Sans as pictured below)
  4. With the Text Tool selected, click on your blank image and the GIMP Text Editor will pop up. Enter the text you would like, I'm using my name. *Note 2
  5. Now we will move the text to be close to center and adjust the size. You will be jumping back and forth on Step 4 and 5 until you get it the way you like.
  6. Select the Move tool and select the "Move the active layer" option. Select the layer of text found on the Layers, Channels, Paths window. Go to your image and move that layer to the top left.
  7. Select the Font tool again and click on the text in the image. Adjust the font size so your text will be the best fit. It does not have to be perfect.
  8. Now we save. On the image window, select File > Save As. In the save image window, choose a location and unique name and set the Select File Type as TarGA (.tga). I used DravenTag for my file name. Use your own unique name and remember to replace "DravenTag" throughout this tutorial with your decal name.
  9. An Export File window will pop up. Make sure Merge Visible Layers is selected and hit Export. A Save as TGA window will pop up. Both boxes should be checked and hit Save. You can close GIMP now.
Converting TGA to VTF What is the VTF (Valve Texture File)? It is an image file in a format that Source uses.
  1. Run VTFEdit and choose File > Import. Browse to your .tga file and open it.
  2. The VTF Options window will open, just press OK. If you used black text, your texture will look solid black.
  3. *Note 3
  4. Choose File > Save and choose the name of your tag. Mine is called DravenTag.vtf
  5. Close VTFEdit and move the .vtf file to your "counter-strike source\cstrike\materials\decals" folder. Make the decals folder if necessary.
  6. Leave this folder open for the next step, Creating the VMT.
Converting TGA to VTF (Alternative) Use this only if you're having problems with VTFEdit. This is also good for converting lots of .tga files at once. For more details on this, visit Valve's Wiki
  1. Open a folder to "Steam\steamapps\yourname\sourcesdk\bin\ep1\bin"
  2. Find Vtex.exe then right click the file and select "create shortcut"
  3. Copy or Cut the shortcut
  4. Open a folder to "Steam\steamapps\yourname\sourcesdk_content\cstrike\materialsrc"
  5. Make a New Folder in the materialsrc directory named decals
  6. Paste the vtex shortcut in this directory
  7. Move your .tga to this directory
  8. Drag your .tga on to the vtex shortcut.
  9. A command window will open; press any key when done. If everything worked a txt file will appear with the name of your decal.
  10. Open a folder to "Steam\steamapps\yourname\counter-strike source\cstrike\materials\decals". Make the decals folder if necessary.
Leave this folder open for the next step, Creating the VMT. Creating the VMT File What is the VMT (Valve Material Type) file? It is a plain text file that tells hammer how to handle the VTF you just created. It tells hammer if your image is a decal, brick wall, sky, etc.. All materials in hammer must have a VMT. You can find more info on the VMT on Valve's Wiki
  1. While still in the decal folder where your VTF is placed and make a new Text Document (just right-click New > Text Document).
  2. Open the new text file and copy and paste the info below, replacing DravenTag with your VTF name (Notice there is NOT a .vtf extension below): "LightmappedGeneric" { "$basetexture" "decals\DravenTag" "$decal" 1 "$decalscale" 0.25 "$translucent" 1 } You can change the "$decalscale" if you want. If you make the decal bigger, it will not be as clear and sharp as it is at 0.25. This number should be be between 0.1 to 1 (10% to 100% of the original image size) *Note 4 **ADVANCED NOTES** Multiple VMTs for single VTF file (Skip to Step 3 the first time you read this tutorial!!) You were warned :) You can make mulitple materials off one VTF because the name of the VMT does not have to match your VTF. The Hammer material browser looks for the VMT file and the VMT defines what VTF to use and how to use it. Notice the above definition for our decal. The $basetexture is asking where the .VTF is located inside your cstrike/materials folder. You are telling it that it is in the \decals\ folder and the VTF is named DravenTag. You can copy your VMT, edit it with notepad, change settings, then save it with a different name. For example, you can make 2 VMT files for this decal we just made; one with decalscale of 0.1 and one with 0.25. So you can name the .25 scale vmt something like DravenTag_L.vmt and one with a scale of .1 and name it DravenTag_S.vmt. Once in hammer you will see them both.
  3. Once finished we need to save it. Choose File>Save As in notepad and save it with the settings below; again replacing "DravenTag" with your decal name. (Notice Save as Type is "All Files")
You should now have two files in your "counter-strike source\cstrike\material\decal". One .vtf and one .vmt with the same name. Placing the Decal in Hammer
  1. Open Hammer and Open your map.
  2. Select the Browse button from the Texture Tool.
  3. Type your tag name *Note 3
  4. Select the Decal Tool on the left hand menu.
  5. Click somewhere on your map in the 3D view
You should end up with something like this:

DON'T forget, since this is a custom texture, you will need to use PakRat to include the file in your finished .BSP

For any questions, post below. I hope you found this tutorial useful. --------------------------------------------------------- *Note 1 Your image size, both width and height, must be an exponential of 2, but can be any combination -- Ex. 64x256 1024x32 512x2048 etc. *Note 2 You can add more text boxes by clicking a different blank area in the image with the Text Editor is open. This is useful for doing different colors in the same tag. *Note 3 VTFEdit and Hammer's Material Browser both render the Transparent background as black. This is normal, so don't freak out, you did not mess up. *Note 4 With a decal scale of .25 your image will be 1/4 the size it was in GIMP. In this case, the decal will be 128x64. This will make your decal look sharp. Making it bigger will make it very blocky, so recommended settings are 0.1 to 0.25. It is HIGHLY recommended that you only do .25 and if you want the decal to be bigger in game, use an overlay
Login or Sign up to access this!
Login or Sign up to access this!

Comments

No comments yet!

Embed

Share banner
Image URL
HTML embed code
BB embed code
Markdown embed code

Credits

Key Authors
Draven
Unknown

Author

DravenCreator
Login or Sign up to access this!
Login or Sign up to access this!
Login or Sign up to access this!

Game

Login or Sign up to access this!

Category

Tags

Details

Difficulty Level
Intermediate

Share

  • 2
  • 112.9k
  • 15
Login or Sign up to access this!
arrow_back