Skip to content

Creating Simple Addons

offyerrocker edited this page Apr 7, 2022 · 2 revisions

Start

All "Simple" Addons are installed inside of the mods/saves/ACH Addons/ folder.

Inside each of the addon type folders- the "Crosshairs", "Hitmarkers", and "Hitsounds" folders- is where any given Addon folder should be.

Here's an example of a Hitmarker addon folder correctly installed:

And here's what the addon folder's contents look like:

Start by creating your own folder to house your addon, and try to give it a unique name so that it will not cause conflicts with other addons. I will refer to this as your "[b]Addon Parent Folder[/b]." With a special exception in certain cases for Hitsounds, all content inside of your Addon Parent Folder will be detected as part of the same addon; for example, even if you have multiple texture files in your crosshair or hitmarker, they will all be shown at once as a single unified crosshair/hitmarker when you select your addon.

In each of the examples at the bottom of this page are credits.txt files- these are by no means necessary for the functionality of addons. These are simply common courtesy (and in some cases, required by the license of your source content) if you are not the original creator of the source file- even if you worked very hard on converting them or making this addon, you should always try to credit the original author/creator/source!

Creating Simple Addons for Crosshairs or Hitmarkers

Crosshairs and Hitmarkers are in essentially the same format, so they have been consolidated into a single tutorial.

Crosshairs and Hitmarkers must be in .texture format for the game to read. .texture files are .dds file formats that have been renamed to .texture extensions. Personally, I use Adobe Photoshop with Nvidia's DDS exporter plugin to create my texture assets.

Keep in mind that each texture is automatically centered to the center of the screen, so if you wish for any part of your crosshair to be off-center or asymmetrical, you should either include "whitespace" in the image to offset this center, or create an Advanced Addon instead.

Once you have your .dds file(s), you can rename the file extension(s) to .texture and drag them into your Addon Parent Folder. You can also rename them however you like. Again, try to avoid special characters.

All .texture files inside of your Addon Parent Folder will be counted as part of the same crosshair.

You're done! You can now place your Addon Parent Folder inside of the ACH Addons/Crosshairs/ or the ACH Addons/Hitmarkers/ folder, depending on the addon type.

Creating Simple Addons for Hitsounds

Hitsounds must be in .ogg format for SuperBLT's XAudio API to read. They can be any length, but for the application as Hitsounds specifically, should not be too long- I suggest a length of around 3 seconds of audible sound at most, but you can do whatever you like.

I recommend Audacity as free software for editing sounds and converting them to .ogg format.

Once you have your .ogg file(s), place it inside your Addon Parent Folder.

ACH supports "sound variations" for hitsounds- that is, if you have multiple variations of the same sound, or want a random sound from a set of sounds to play instead of the same one every time, you can easily do so by also creating a file called random.txt inside your Addon Parent Folder. (The contents of random.txt do not matter at all.)

  • If multiple .ogg files are present inside of the Addon Parent Folder, and random.txt exists:
    • The name of your Addon Parent Folder will be used as the addon's display name when selecting the hitsound in the ACH Hitsounds menu.
    • When your addon hitsound is triggered, ACH will select one random .ogg file from the .ogg files in your Addon Parent Folder to use.
  • If multiple .ogg files are present inside of the Addon Parent Folder, and random.txt does not exist:
    • Each sound will be added as a separately available hitsound.
    • The name of each respective .ogg file will be used as its display name when selecting the hitsound in the ACH Hitsounds menu.

You're done! You can now place your Addon Parent Folder inside of the ACH Addons/Hitsounds/ folder.

Finished Example Addons

The following example addon packs provide useful templates and comments for creating their respective addon types:

Crosshair Pack Addon: https://modworkshop.net/mod/29819

Hitsound Pack Addon: https://modworkshop.net/mod/29820

Hitmarker Pack Addon: https://modworkshop.net/mod/29821

Clone this wiki locally