Jump to content

Home

Crosshairs????


mrdrVamp

Recommended Posts

In the \gfx\2d directory in the pk3 (you can open it with winzip) there are some files named crosshaira.tga, crosshairb.tga, etc. These files control the crosshair image. I'm not sure which one is actually used, so you will have to experiment. Also, the shape is defined by the image's alpha channel, not the color. If you open them up, they will be solid white. You will need a program that can edit the alpha channel in order to be able to change the crosshair. Changing the color wouldn't have the expected effect, because the engine blends the color of the image with another color to get the color you see.

 

I made a mod that replaced the crosshair with the one from some of the older screenshots (it was a small circle with 8 "spikes" coming out of it), but I was too lazy to find the crosshair that was actually used, so I just replaced all of them.

 

I'll upload the mod to the jk2.net file section tomorrow sometime around 3 pm EST tomorrow (If I don't forget :) ). The mod also adds glow on the floor from all the projectile weapons and colors the purple lightsaber images in the GUI to be the same color as in the game (just a few misc. differences that I think are kinda neat).

Link to comment
Share on other sites

I edited the cropcircle.tga to change the appearance of the disrupter rifle scope. I'm trying to give the sniper rifle an actual crosshair, go figure. I added a little cross in the center of the circle, and used winace to put the file in the correct dir. in one of the pk3 files. But it doesn't show up in the game. Anybody know what's going on? I would really like to have a crosshair on the sniper rifle.

Link to comment
Share on other sites

How you do it depends heavily on what program you are using.

 

With Photoshop, all you need to do is go to the window menu, click Show Channels, then click the item labeled Alpha 1 in the window in the lower right of the screen. The document will now allow you to edit the alpha channel instead of the colors.

 

With Paint Shop Pro, you would need to load the mask into a selection, add the non-transparent areas to the selection, and then save the selection to an alpha channel, but the proccess is a bit too complicated to explain; try searching for PSP tutorials if you need more help.

 

With any other program, the procces would be best explained by the program's help.

 

If you don't want to go through this, you can (for this particular project, at least) simply change the blend-mode used for the texture. To do this, open \shaders\effects.shader from assets0.pk3, find the section referring to \gfx\2d\cropcircle2.tga (cropcircle.tga is the zoom indicator, cropcircle2.tga is the scope itself) and change the line that says "blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA" (it is line 766) to "blendFunc GL_ONE GL_ONE". This will cancel the usage of the alpha channel, but it will make the darker areas more transparent, so the crosshair couldn't be anything too dark, or it wouldn't show up.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...