Animated Counter-Strike: Source Spray Tutorial
Using Adobe PhotoShop 7.0 or similar software
|
|
White Background is used simply to make it visible on the website background
|
Introduction:
So... You're interested in making an animated spray? This tutorial is here to help you! This is not a PhotoShop tutorial however, so I will pretend that you have some working knowledge of PhotoShop or another paint type program. Don't have PhotoShop? Don't worry! Any paint or draw software will work, but it must be able to save the images files as Targa files (filename.tga). However, the program you need to use to convert the targa file to a Counter-Strike: Source spray file can be download from here. This a ZIP file that has a basic program that converts Targa files in to Source files The best place to unzip this file is somewhere in the Valve or steam contents folder, preferable under the Counter-Strike Source directory. Under "materials" would be great.
A little bit about alpha channels. Alpha channel is the area that is basically see through, or the part of what ever you create that is not painted. This is usually defaulted to white by most paint programs (even Photoshop). However, some paint programs that work with layers (like Photoshop) allow layers to be transparent, which is what will be used in this tutorial. Transparent layers have a blank or nothing background that will be see through (clear) when the file is saved using alpha channels. PhotoShop will show a gray/white checkered board pattern when using transparent layers. IMPORTANT!!! It is NOT necessary to use alpha channels to make animated sprays! Alpha channels just add that really cool spray look that the stock sprays have that come with Counter-Strike: Source. If alpha channels don't work then use a picture or paint the entire background.
A quick tip: LESS is MORE! A quality spray is simple!
Okay... Let's begin. 1. Open a NEW project under the file tab.
Notice transparent is selected this allows for clear layers and ultimately alpha channels notes: Here you can name your project. size: VERY IMPORTANT! 256x256 is the largest size allowed in CS:S and cannot be animated because the file will be too large. One frame only or just a picture. I use this size (256x256) to create and work with the individual frames then I decrease the size to 128x128 to animate. It makes for a crisper animation. 128x128 up to 5 frames (my animations are 128x128 and 2-5 frames in length) 64x128 ???? I'm experimenting with this size, but alpha channels don't seem to work on this size. 64x64 10-20 frames, but there is a HUGE quality loss at this size.
2. Now think of what you are going to do and animate. In this animation Sammy is getting shot in the head, which seems to be typical when Sammy plays CS:S. Here I draw my basic SAmmyCAt face all relaxed as if nothing wrong.
NO ALPHA CHANNEL on or selected 3. Next we need to ADD the ALPHA CHANNEL, so that when this is sprayed all you see is the sprayed cat head. If you do not have the ability to alpha channel with your paint program, then the background square will be white. Then try a layer behind that is painted or has a picture.
Add an alpha channel by clicking here in PhotoShop the back ground will now have a pink see through appearance.
4. You can shut the Alpha channel off while you work by clicking the eye to the left on the alpha channel (under channels), so that you can see the actual colors that will be sprayed. However, don't forget to turn it back on before you save or it will have a white background.
5. Time to save the first frame. Resize the picture frame to 128x128. Save to the place where you unzipped the spraymaker file, and to the extension shown below. SAVE AS a targa or .tga file. m(where ever its unzipped)\SPRAY MAKER\hl2\materialsrc\animated IMPORTANT: the name of the file MUST be named: spray001 because its frame 001
24 bit will be plenty detailed or 32 bit can be used
6. Resize the picture back to 256x256 or use the undo function. Now I'm going to change my picture some to create frame 002. I erased just the closed eyes and made them open for frame two. Resize picture to 128x128. Alpha channel selected, SAVE AS spray002. Resize back to 256x256 or use the undo function. Notice the fear in Sammy's eyes? That is because of what happens in the next frame.
7. The headshot! In this frame erase the both eyes and make eye to the left an x.
8. Add a new layer, so that the splat can be added. Click on the layer the head is in and deselect it, so that, only the splat area is visible. Use the smudge tool to get an affect similar to this. Now add the head back to the background.
9. It should look like the one below. Remember I leave the Alpha channel on so the Cat head is really black and the splat is more red.
10. Time to save frame 003. Resize frame to 128x128. SAVE AS spray003 in the same file directory as before and as a Targa file. 11. Resize back to 256x256 or use undo function. Erase the right upper portion of the head as below. You can delete the splat layer or deselect it so that it is not seen or saved. I added the phrase "Headshot Again?" to the new found emptiness of Sammy's head.
12. Resize to 128x128. SAVE AS spray004 as a targa file. Resize back to 256x256 or use undo function. 13. The next frame I just move the words slightly and resize to 128x128. SAVE AS spray005 as targa file. WE are now done with making the 5 frames of the animation. (keep words up for at least 2 frames) 14. Using MY COMPUTER or whatever you choose, go to (where animated spray file was unzipped) \SPRAY MAKER\hl2\materialsrc\animated and open the text file. It should look like this...
15. If the spray was only 3 frames long (file names spray001, spray002, and spray003) then the start frame would be 1 and the end frame would be 3. This animation is five frames long so the start and end frames are correct. Under the file tab, select save. 16. Now go back to here.
note: I do not have my file in my steam directory, but it would make things much easier if you did. 17. Double click on the convert batch file and the five frames should be converted into a usable CS:S spray file. However, it is in the wrong place and the file needs to be renamed and moved, so that, you can use it in Counter-Strike.
note: there are two files spray.vmt and spray.vtf. Rename the file to whatever sounds good, but leave the file extensions on the files. Example: rename the files to headshot.vmt and headshot.vtf. The files MUST have the exact same name! The other files you see in the picture are sprays that have already been made and renamed. Once the files have been renamed, the files must be moved to the materials directory under the steam/counterstrike directory. Oh yeah!, if the .vtf file is larger then 138 kilobytes it will not work on the internet servers, as that is the file size limitation.
18. Now copy/cut and paste the renamed file to this directory. F:\Program Files\Valve\Steam\SteamApps\(steam acct name)\counter-strike source\cstrike\materials\VGUI\logos
19. Now the spray should be accessable in CS:S.... let's see.
Notice the background is gray. If its white then the alpha channel wasn't done right or it doesn't recognize the alpha channel format used.
The possibilities are endless! Strike fear into your enemies. Intimidate them! Taunt them!
Troubleshooting Your Spray I get a white background, what can I do? Hmmm? I use PhotoShop 7.0 and don't have a problem. This is my suggestion, go to the maker of the product's website and see if you can find out how to use alpha channels with targa files properly. It may just be an incompatibility issue with your software and the Source spray file. Kondore has PhotoShop 5.1, which allows the use of alpha channels, but every time we saved his files and converted them, We got a white background. He now makes his sprays on my computer when he makes a spray using an alpha channel. Photoshop 5.1 targa files with alpha channels are just incompatible. There are also ways around using alpha channels, like using a background. I have several animated sprays where I use a picture of Sammy, add some flashes to the eyes and the word "DIE" also flashes. It actually a cool spray, and maybe I've used it on you!
The animation is to fast, what do I do?
If you use 128x128 you are limited to five frames, and if every frame is very different from the other, then it has a quick feel to it. In other words, When you add words leave them in at least two frames and its only five frames long so KEEP IT SIMPLE! Don't try to do so much! Here is an example of how I would do a worded animation. On a very cool picture of Sammy I would write "you just got owned by a...". I would leave this up for at least two frames. Then the word "CAT" would pop up next for three frames. I would also very very slightly move the word "CAT" through those 3 frames. Remember a good animated spray is really simple and not complicated, so therefore, keep it simple! Simple! Simple! Simple!
I want a longer more complicated animation! And so would I ! I am going to experiment with 64x128 size to see what I can come up with on that size, which does seem to work. However, Alpha Channels don't seem to work with this particular size. 64x64 allows for a fairly long animation, but the picture and word quality is fairly low. The animation is longer, but your spray just will not look as good as the 128x128 sprays. Remember there is a 138 kilobyte limitation to your spray size, if its any bigger it will only be seen on your computer and not on the server. Nobody else will see it, so then what's the point!?!
|