TOXIKK
Otillräckligt med betyg
Creating / Using Custom Crosshairs
Av 76561198027781948
A fully comprehensive guide on how to use custom crosshairs for TOXIKK, as well as creating your own.
   
Utmärkelse
Favorit
Favoritmarkerad
Avfavoritmarkerad
Introduction / Idea
First, you should probably come up with an idea.

This idea can be anything, from a picture you found on Google to a submitted item that's already in the workshop. Either way, it's going to wind up in TOXIKK. In my case, I'm going to use an image that I found on the internet by literally searching "scifi crosshairs" on Google.



If you came here just to install a custom crosshair that already exists, view the last section of this guide.

Otherwise, let's keep going.

This may look like a massive guide, but I just go into meticulous detail.
Image Preparation
I have an image, but it's not quite ready for TOXIKK just yet.

First, we need to make some slight changes to the image.

Take your image and copy it into your image editing program of choice as a new layer. I use Photoshop. In terms of canvas size, choose a bicubic number that can still hold your image. You can always scale your image, but I chose 64x64 for mine.



Now that you have your canvas size, copy your image to your clipboard. You'll need it later. For now, make a new layer and drag it below your crosshair. Fill this layer with pure white.



With your crosshair image as a separate layer, click Channels on the bottom-right. Your image program maybe different, but the goal is to get to the alpha channel.



My image doesn't have one yet, so I'll create it.



In Photoshop, creating the layer automatically sets it as the active one. We don't need it just yet though. Click on the RGB layer and open the Layers tab. Hide your crosshair layer for the moment, we don't need it.



Make a new layer and drag it above your white layer. This will be a temporary layer, but it'll come in handy for alignment. I know that my image is 64x64, yours may be different. Divide your image by 2 and remember this number.

With the Rectangular Marquee tool selected, in the top-left, set the style to Fixed Size. For width and height, set them both to half of your image's size. I'm using 32 for each.



Set your color to something that will stand out, I'm going to use blue. We want to select the top-left and bottom-right quarters of the image. You can hold Shift to make multiple selections.



Fill these in with the color that you have selected. Optionally, you can do Select > Inverse to select the other quarters. For convenience, you can fill those in with a separate color.



The point where these 4 boxes meet is the center of your image. This is important, since crosshairs have to be marginally accurate. In your Layers tab, show your crosshair layer again and set its style to Lighten.



Now the white part of your crosshair is showing, and you can line it up as necessary. In Photoshop, you can use the arrow keys to nudge your layer per pixel. Line the center of your crosshair up with the center of the boxes.



With a dark-ish background like blue and red, you can also get a good idea of how your crosshair will look in-game. I want mine to look a bit stronger, so I'm going to brighten it by using Image > Adjustments > Brightness / Contrast.



This is good enough, since I'm using the image for a tutorial anyway. At this point, you can tweak your image as necessary to make it look decent. When you're finished, set your crosshair layer's style back to Normal. Fill in the outer edge of it with a solid black color.



Now do a Select All (Ctrl-A) and copy this layer to your clipboard. This will become the alpha channel. Hide all layers except for the white that you created earlier.



Next, click the Channels tab again. Select your Alpha layer, and paste in the image that you created earlier. If all goes well, it should look something like this:



At this point, you can flatten your image by doing Layer > Flatten Image. The final step is to set your image to RGB color by doing Image > Mode > RGB Color.



Your crosshair image is ready to go.
Save it as a .tga file in a position of your choice. Be sure you save as 32-bit!
Packaging Your Crosshair
Now that we have a crosshair image, we need to get it in-game.

With your image saved, start up the Toxikk SDKK. If you haven't installed it yet, you can follow this guide.[forum.toxikk.com]

First, we need to import our image. Between the thumbnail spaces in the Content Browser, right-click the background and click Import at the top.



Locate the .tga file that you saved earlier, and a new window should appear. For the package, you can type whatever you'd like. I start mine with XH_ for convenience. Name can be left alone if you'd like, but don't make it anything too complex.



In the scrolling list beneath these 3 boxes, you should see an option called LODGroup. Set this dropdown box to TEXTUREGROUP_UI.



Go ahead and pick OK. Your crosshair image should now show up in your package.



Just to be sure, double-click it and make sure the background is transparent. If it's black, then you messed up in the alpha channel part of the last section.



While you're at it, scroll down on the right and uncheck SRGB.



In the left part of the content browser, scroll down to the bottom and find NewPackages. Beneath it, you should see the package that you just created. Right-click it and pick Save.



If you're using Chatouille's fast cook method[forum.toxikk.com] then save this file in
steam/steamapps/toxikk/UDKGame/PackagesToCook.

Otherwise, if you're using the standard method, just saves it in
steam/steamapps/toxikk/UDKGame/Content.

Before closing the editor, you'll want to get the "path" to your image. Paths go as follows:
Package . Group . Name

In my case, the package is XH_GuideExample and the name is scifihair. Put it in a text document or something so that you can refer to it later.

XH_GuideExample.scifihair

You're done with the editor, you can close it now.

As always, I'm not going to go over how to cook your package. There are simple guides out there. If you're making this for personal use, cooking is optional.

Chatouille's Fast-Cook Guide[forum.toxikk.com]
Official Guide[forum.toxikk.com]
Using In-Game
Your crosshair exists and is ready to go, but how do you use it?

Using a custom crosshair is simple. Find your UDKWeapon.ini file in Steam/Steamapps/Toxikk/UDKGame/Config. Open it in Notepad or Notepad++, a text editor of your choice. Immediately, you should notice a lot of crosshair lines.



At the end of these lines, you will also notice a part called CustomTexture. Remember the reference you saved earlier? This is where you'll need it. Mine was:

XH_GuideExample.scifihair

For a workshop item, this will usually be supplied for you. Surround it in quotes, and add it after the CustomTexture= section of the weapon that you want your crosshair to be applied to. I'm going to apply it to my Violator.

CustomTexture="XH_GuideExample.scifihair"

Also note that this same section exists for all layers. Make sure that you apply it to the layer of your choice.

Save this file and start up Toxikk.
Check your crosshair menu and select the weapon you applied the texture to in the INI. If all goes well, you should see it working.



At the time of writing, custom crosshairs are aligned from the top-left rather than the center. To align your crosshair properly, make a separate layer with a small dot image from TOXIKK.



From there, you can use the offset values to align the center of your crosshair up with the dot. This ensures that it will be in the center of your screen. It may or may not be half of your image's size, that's a good way to test.



Congrats, you have a custom crosshair.
Final Words

Hopefully this guide has been helpful and you can create your own custom crosshairs. They're simple to make once you nail the process, and it adds a sense of uniqueness to your game.

Sharing your crosshairs is simple, just provide the .upk and the reference line that should go in the .ini.

If you wish to use the crosshair that I created with this example, you can download it below.


XH_GuideExample.scifihair
Download[dl.dropboxusercontent.com]

Thanks for reading!
3 kommentarer
Hellrunner 13 sep, 2016 @ 12:46 
oh .. yeah.. nobody in game could tell me how to change it... sry to bother you... ^^ AH .. it's all there. Under Weapons in the Options, nice ^^ ... Comp potential confirmed XD
76561198027781948  [skapare] 13 sep, 2016 @ 12:40 
There's already a simple dot in the standard crosshairs. :approved:
Hellrunner 13 sep, 2016 @ 12:35 
oh wow.. as simple as that ^^ ... no seriously that has to change. a big selection in game and easy file replacement for customs ... but simple dot and the option to scale it should be mandatory. great game.. love it so far ^^