Jump to content
Official BF Editor Forums
Sign in to follow this  

Getting HUD icons ingame.

Recommended Posts

this files are used in bf2 for huds icon like the vehicle icons flags icons etc.

first what its an atlas very easy an atlas its a dds picture that has to be generated by a program on you bf2 folder called dice_TextureAtlasTool.exe

its opened by the cmd promt try clicking run type cmd and draga the file to the window then hit enter. that will help

where they are supposed to be stored?

on the menu_server.zip should be that .tac file and the .tai file

and on the menu_client.zip should be the dds pictures

wtf Its and .tac file?

the tac file its a notepad made fil with the .tac extension that tell the program where the pictures are and the directory.

here its an example.

group MenuAtlasMemeAtlas_01 width 2048 height 2048 format dxt5 miplevels 1 border 2



MenuHUDTextureIngameWeaponsIconsHudPredatorAT_crosshair.tga border

MenuHUDTextureIngameWeaponsIconsHudATSATS_crosshair.tga border

MenuHUDTextureIngameWeaponsIconsHudATSATS_sight.tga border

MenuHUDTextureIngameWeaponsIconsHudWASPwasp_defence_crosshair.dds border

MenuHUDTextureIngameWeaponsIconsHudWASPwasp_defence_crosshair2.dds border

first the header the


thats where the file its going to be stored. and the name

width 2048 height 2048

that tells us th size of the atlas file. the limit if its excedded the program will continue on another one. automatically and the size to has to be that one as its the maximum for bf2.

format dxt5 miplevels 1 border 2

thats the format left that as it its.

you can have comments in there so if you have and file and dont want to put it on the current atlas put the # before the path.

Microsoft Windows XP [Version 5.1.2600]

(C) Copyright 1985-2001 Microsoft Corp.

C:Documents and SettingsJose>"D:Program FilesEA GAMESBattlefield 2dice_TextureAtlasTool.exe"

dice_TextureAtlasTool.exe [-h] [-o <outfile>] [-output_path <output path>] [-inp

ut_path <input path>] [-format <format>] { -i <infile> | [-nomipmap] [-maxres <r

es>] <img1> [<img2> [à] ] }

  -h                         prints this usage help

  -nomipmap                  only writes out the top-level mipmap

  -maxres <res>              limits texture atlases to a maximum resolution of


  -o <outfile>               specifies output filename

  -i <infile>                atlas configuration filename

  -output_path <output path> atlas destination path

  -input_path <input path>   texture source path

  -format <format>           force texture format

  -auto_texture_list <texture_path>    supply a path so the texture list is aut

o generated for all textures within the given path including sub-directories. a

.tac file is not needed

    If an input path is provided the texture path should be relative to the inp

ut path.


  dice_TextureAtlasTool.exe -o atlas -i config.tac

  dice_TextureAtlasTool.exe -o atlas -format dxt5 texture0.dds texture1.dds ...

  dice_TextureAtlasTool.exe -o atlas -auto_texture_list MyProject/MyTextures

this is the command you should use

dice_TextureAtlasTool.exe -o atlas -i config.tac

also you has to have a menu folder as that where the program will seach for the picture.

also the pictures has to be tga as tga has alpha and most hud pics have alpha. havent tryed other format.

Menu/HUD/Texture/Ingame/Weapons/Icons/Hud/Selection/hellfire_missile.tga  MenuAtlasMemeAtlas_020.dds, 0, 0.364258, 0.616211, 0.0732422, 0.0214844

k now that over there its the location of that picture.


you have to use that whole path when telling where the picture its.


thats it where the picture its on the second atlas file.


thits its the atlas idx(not sure what it its.

0.364258, 0.616211,

first its wide offset where the picture itc located in wide.

the other its the heighoffset thats where its in hegiht of the file.

0.0732422, 0.0214844

thats the size of the picture.

the command for making the atlas should be the following one.

 dice_TextureAtlasTool.exe -o atlas -i MemeAtlas.tac

Share this post

Link to post
Share on other sites


Like paladin said try creating a new atlas.

If there aren't many files to add you can just use this command:


"C:Program FilesEA GAMESBattlefield 2dice_TextureAtlasTool.exe" -o MemeAtlas_03 -format dxt5 image1.tga image2.tga

It'll generate 3 files:




MemeAtlas_03.tai, Put this file in your mod_menu_server.zipatlas directory

MemeAtlas_030.dds, Put this file in your mod_menu_vlient.zipatlas directory

AtlasList.con, this file needs to be edited a littlebit,

It should contain this code:


hudManager.addTextureAtlas "MemeAtlas_03.tai"

Change it to this


hudManager.addTextureAtlas "MemeAtlas_03.tai"

hudManager.addTextureAtlas "MemeAtlas.tai"

This will make it load the originall bf2 atlas and yours. Also this file have to be put in mod_menu_server.zipatlas

*note: the atlaslist.con is only needed if you're going to replace images from bf2 by your mod ones using the BF2 image names

Ofcourse if you got alot of files to put in an atlas, its better to use a *.tac file as input.

I hope this helps

thx for that [R-DEV]ArchEnemy

Share this post

Link to post
Share on other sites
Ells]In terms of the images themselve's (TGA's), are these just white image on black background or some kind of mask layer??

They are alpha channels. IN PS go to channels and you'll see it.

Share this post

Link to post
Share on other sites

Just a side note for those dont quite understand.

you will find two formats used by the menu. ".tga and .dds"

The reason you find these two formats is that .dds files can only be created from a texture divisable x 2 ,another words

A 32x32 pixil image should be a .dds file

while a 32x140 image will have to be .tga

I would suggest that using .dds file when ever possable to keep menu texture size to a mininium.

Dxt 5 w/alpha, no mipmaps

Share this post

Link to post
Share on other sites

Its a bit confusing on first sight cause some backslashes went away in the first post.

More info on Atlasses and the Tool for them can be found here :


Still more info can be found when searching this forum for 'dice_textureatlastool.exe'

Keep in mind you should never replace the original atlasses from BF2 with your own one as they are subject to patches - overwriting your own. A few of the early mods for BF2 suffered from this problem. Instead add a new atlas for the mod you're working on.

Share this post

Link to post
Share on other sites

I'm a little confused by this tutorial...

Maybe its easier to explain what i DO understand about this process, rather than what I don't. I have been able to successfully 'port the SF RPG into my mod, including getting the icons to work successfully in-game. How I did this was a matter of copying the xpack1atlas0.dds, the xpack1atlas.tai, and the appropriate icons from the Menu\HUD\Texture\Ingame\Weapons\Icons\Hud folder and selection sub-folder into their respective folders in my mod. I then deleted most of the entries in the .tai and .tac (except the ones I needed for the RPG), and then ran Rex's menu packer tool. However, I realize that if I continue to do things this way, I'd need a separate atlas for each thing I wanted to put into my mod. So the question then becomes, how do i go about creating one large atlas? I apologize to whoever wrote this tutorial, but I have alot of trouble understanding what is trying to be conveyed. Could someone just post a step-by-step outline on how to do this? I don't need the pictures and fancy stuff, but a simple outline of how to accomplish what I'm trying to do would be greatly appreciated. Thanks for your time in advance.

Share this post

Link to post
Share on other sites

When you want to add a new icon to your existing atlas, just enter its path into your MemeAtlasNNN.tac file and run the menu packer again. The icon ends up in your existing atlas. The TAI file will be created by the menu packer.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this