Objective Icons


standard_dod_obj_icons
custom_obj_icons
Size of icons.
You can change the size of the icons by editing the HudLayout.res file, find this section…
}
HudObjectiveIcons
{
"fieldName" "HudObjectiveIcons"
"xpos" "0"
"ypos" "0"
"wide" "150"
"tall" "50"
"visible" "1"
"enabled" "1"
"iconsize" "24"
"icon_start_x" "5"
"icon_start_y" "5"
"separator_width" "2" // distance between the icons (including their backgrounds)
"CornerCutSize" "0"
"BackgroundOverlap" "-1" // amount the background overlaps the icons (width and height)


Change the size, "iconsize" "24" change to "20 or "18 or whatever you want, within reason you can adjust to suit.


Positioning.

"wide" this value sets the width size for workable area you will allow the icons to fit in ... make the icon size big (say 50) and set "wide" at "150"... you will find the icons cut off! Standard is "600". I used "150"... because that's all I needed :)

"tall" Same as above but for the height size... standard is "200".

"separator_width"
controls the distance between the icons, use around "2" if you have no background a value of "5" is standard.

"icon_start_x" is the start point of where the icons will sit on the screen left to right. (their position is controlled all together as a block).

"icon_start_y" is the start point of where the icons will sit on the screen up and down. (their position is controlled all together as a block).


Change or Disable the Icon Background.

"BackgroundOverlap" "-1" This value hides the background under the icon, the standard is "4" so play around with it to suit.

The problem of changing the Objective icon to a custom icon

There are a couple of reasons you would want to do this, say you have a mod to your HUD files that changes the US Army to British, you have changed all the player skins, sounds and HUD items to have British icons...what about the objective icons!!!

It is possible but a pain to do. The old dod and dod:s file structure was set out to look in the dod/materials/sprites/obj_icons, now if you placed a icon with a british flag instead of a US flag icon, with the same name but different graphics, in that folder it would over-ride what the mapper and the game intended to display.
In one of the many "improvement" updates to the orangebox engine, this has now changed.
At first this looked impossible, it is possible but is now quite a big task to do, you now have to tell the game files via a entry into the dod/scripts/mod_texture.txt file as well as make new images for every icon of every objective icon VALVe has made as well as all custom map icons and any new new ones yet to be made!!!
Thats why a lot of people who used tio make this stuff...stopped doing it. It's just too hard now.
But... if you want to try here is the outline of what you need to do.....
* Extract the files from the .bsp file using "Packrat" http://www.geocities.com/cofrdrbob/pakrat.html

* Take note of the files addresses in packrat, these are also mentioned in the .VMT file.

* Modify the vtf custom file, place in folders the same as mentioned in the .bsp or VMT files.

* All will work When the file is mentioned in the dod/scripts/mod_textures file...


}

"icon_obj_allies" //standard mod_textures entry
{
"file" "sprites/obj_icons/icon_obj_allies"
"x" "0"
"y" "0"
"width" "64"
"height" "64"
}

"icon_obj_axis" //standard mod_textures entry
{
"file" "sprites/obj_icons/icon_obj_axis"
"x" "0"
"y" "0"
"width" "64"
"height" "64"
}

"icon_obj_oak_allies" //******dod_churchyard_b5*******
{
"file" "sprites/obj_icons/dod_churchyard/icon_obj_oak_allies"
"x" "0"
"y" "0"
"width" "64"
"height" "64"
}

"icon_obj_oak_.....
... you get the idea, the latest list of map icon names are in the latest realease of
the mod_texture files of my Metal Hud Ver 1, it has some custom objective icons using the mention method.

Sometimes a mapper will use a icon that is already in the custom set..

DO NOT PUT THE SAME ICON NAME TWICE!!!! see below.

The dod_flurry_b1 and dod_flurry_b2 problem

dod_flurry_b1 and dod_flurry_b2 did not work with this method and I thought it was a couple of things but here is one thing in the VMT file....

+++++++++++++++++++++++++++

"UnlitGeneric"
{
"$translucent" 1
"$baseTexture" "sprites/obj_icons/flurry/icon_obj_88_allies"
"$vertexcolor" 1
"$no_fullbright" 1
"$ignorez" 1
}

+++++++++++++++++++++++++++

The "$baseTexture" address should be ... "sprites\...." (the slash is wrong.)

+++++++++++++++++++++++++++

"$baseTexture" "sprites\obj_icons/flurry/icon_obj_88_allies"

+++++++++++++++++++++++++++

Also it may be that the mod-texture.txt file will only accept on instance of "icon_obj_88_allies" a filename also used by other maps....
dod_anvil, dod_harbor_rc1, dod_flak_b6, dod_strand_rc1 and b4

With all of those maps above I can get the custom icons for the "icon_obj_88..." to work... because the VMT file is correct and the folder used is dod\materials\sprites\obj_icons.

What does this mean? dod_flurry_b1 and dod_flurry_b2 had to go unsupported as there
were more mapps sharing the same icon.

You cannot have two icon names "icon_obj_88_allies" going to two "file" adressess.

The situation below is two "icon_obj_88_allies" entries, this does not Work!



}

"icon_obj_88_allies" //******dod_flurry_b1 and b2*******
{
"file" "sprites/obj_icons/fluffy/icon_obj_88_allies" //different folder
"x" "0"
"y" "0"
"width" "64"
"height" "64"
}

"icon_obj_88_allies" //******dod_anvil, dod_harbor_rc1, dod_flak_b6, dod_strand_rc1/b4
{
"file" "sprites/obj_icons/icon_obj_88_allies"
"x" "0"
"y" "0"
"width" "64"
"height" "64"
}


A situation like this cannot be fixed (I can't find a way, tell me if you have)
you are forced to pick between the two and remove on of the enties in the
mod-textures file.

In this case I deleted the entry for dod_flurry_b1 and b2 because the other entry supports more maps.

This broke my heart... dod_flurry_b1 and b2 are my favorites :(


Damn...you read all that... dude! is that hard or what... much easier to just place a image and over-ride the image file!!! But those days are gone, you now need to do the above.

Please Login to post comments, see the top buttons and join dodbits now!