How do i port over my sniper scope sprites?


PhoenixRaven
09-28-2005, 07:12 AM
I created some custom sniper scopes sprites for dod awhile back but i cant figure out how for the life of me to port them over to source how would i go about doing this. Thank you :-)
Chris

PhoenixRaven
09-28-2005, 08:06 AM
Also i pretty much figured out it needs to be a .vtf file (i think) so how do i go about making a sprite a .vtf and where do i place it after words. Please correct me if im wrong.
Thax guys.

PhoenixRaven
09-28-2005, 05:16 PM
anyone?

Tonedef
09-28-2005, 05:31 PM
turn it into a TGA and use some of the tools here http://www.wunderboy.org/

Best site ever!

PhoenixRaven
09-28-2005, 06:28 PM
*LOOKS SHEEPISH* How do i turn my sprite into a targa file? then what directory do i put the .vtf file. Like i said when it comes to doing stuff in regular dod i got it covered. This stuff is a little more advanced.
Thank you

PhoenixRaven
09-29-2005, 12:58 AM
anyone please?

mXed.dk
09-29-2005, 01:56 AM
use PS pr Gimp?
open up your .bmp and save it as a .tga

PhoenixRaven
09-29-2005, 02:13 AM
dont have the .bmp anymore just the .spr anyway i can reconvert it back to a .bmp so i can save it as a .tga?
I did find a program called bmp2spr but it doesnt function correctly an is really old. I appreciate your responses.
If anyone could help out that would be great

PhoenixRaven
09-30-2005, 06:23 PM
please?

Wulf
09-30-2005, 07:20 PM
As I've said somewhere else, I've tried it but can't get the transparency to work, but here's how to get as far along as I have:

1. Get the program Sprite Viewer (google it) and use it to view your scope sprite.

2. Select all 4 parts of the scope sprite and export them to BMP files...

3. Use PSP or Photoshop to add alpha transparency and save as TGA files (this is where it gets screwy for me)

5. Use VTFedit to create the relevant vft files in your materials/sprites/scopes folder.

Like I said, this method doesn't fully work. I've managed to get the black to go transparent, but never the white unfortunatly... Mess around with it and if you get any further along, lemme know and I can get my scopes to work... Likewise I'll post anything I figure out...

P.S. If you don't have it, I recommend you get GCFscape to look through your DoD:S gcf to figure out where everything goes, and how it's supposed to go there...

PhoenixRaven
10-01-2005, 07:49 AM
Thanks for the tip. ;-)

Wulf
10-01-2005, 07:56 AM
I've been working on it again today, and I've made a small amount of progress...

Whenever I was applying the aplha transparency, I was getting the black outline to disappear rather than the bit you'd be looking through (defaulted to white). When creating the aplha transparency, you have to invert the image so that the centre is black and the border and crosshair is white. It's not perfect, but it gave me a scope (http://i6.photobucket.com/albums/y230/lunamoon_av/dod_avalanche0000.jpg) that I was able to mess about with ingame...

PhoenixRaven
10-01-2005, 08:14 AM
Maybe i screwed up somewhere along the line but it made everything into purple and black checker effect...i cant figure it out....is that due to the tranparency problem or did i just mess up somewehere else?
Thax for your help btw

Wulf
10-01-2005, 08:17 AM
I've gotten that once. I've found using the VTF plugin for Photoshop seems to cut this out for me though... If you have VTF edit you can look at your scope. If it's black and white it might work, if it's shades of purple then something's gone wrong somewhere...

If I get the time I'll do a step by step tutorial on how to get as far as i have...

PhoenixRaven
10-01-2005, 10:04 PM
Please do wol. Your an excellent guy you know that :-)
Thax man for all your help and post your tutorial as soon as you get the time :-)

Wulf
10-02-2005, 07:38 AM
If you use the Srite viewer to extract the 4 parts of the sniper scope, you can just clone it over in Photoshop instead of editing the sprite...

Posted in another thread

Originally posted by Genie
Yeah. I used the vtf plugin for photoshop and did the following...

1. Open the vtf
2. go to channels, pick "alpha 1" (the bottom channel) and ctl-i to invert the colors
3. edit it as I wished
4. ctl-i to invert it back
5. file>save
6. Put the vtf's in the proper folder

Day of Defeat Forum Archive created by Neil Jedrzejewski.

This in an partial archive of the old Day of Defeat forums orignally hosted by Valve Software LLC.
Material has been archived for the purpose of creating a knowledge base from messages posted between 2003 and 2008.