AddWeaponIcon Property

Usage:
   ObjectTemplate.AddWeaponIcon image

Argument values:

argument 1:    "Weapon/44magnum.dds", "Weapon/AK47.dds", "Weapon/AKMS.dds", "Weapon/APMines.dds", "Weapon/Binoculars.dds", "Weapon/Binoculars.tga", "Weapon/Blowtorch.dds", "Weapon/C4.dds", "Weapon/CAR15.dds", "Weapon/Caltrops.dds", ...

Description: Gives the file path in Menu.rfa from the Texture directory to the DDS image file (not Targa, despite the suffix) that shows what the weapon looks like. An example filepath: "Weapon/Icon_axisKnife.tga". This icon is shown in the heads-up display, in the bottom middle, when you select a new weapon. This property is specified multiple times for a typical soldier (since he has multiple weapons), and the weapons appear in the order specified.

See the HUD Icon Tutorial for details.

Related properties: AddTemplate, AiTemplate, Geometry, NetworkableInfo, SetKitActiveName, SetKitIcon

Used in object types (and how often in each type): Kit (96%)

Used in a total of 89 .con files: Objects.con

Parent directory of these .con files: objects/Items

Example: (from objects/Items/GerKitdesert/Assault/Objects.con)
   ObjectTemplate.Create Kit German_Assault_Desert
   ObjectTemplate.SetType Assault
   ObjectTemplate.SetKitTeam 1
   ObjectTemplate.Geometry Kit_Axis_Assault
   ObjectTemplate.SetHasCollisionPhysics 1
   ObjectTemplate.NetworkableInfo KitInfo
   ObjectTemplate.AddTemplate Germ_DesertHelmet
   ObjectTemplate.AddTemplate German_hippack
   ObjectTemplate.SetHealthBarIcon "Ingame/Healthbar_empty_assault_64x64.tga"
   ObjectTemplate.SetHealthBarFullIcon "Ingame/Healthbar_full_assault_64x64.tga"
   ObjectTemplate.AddWeaponIcon "Weapon/Icon_axisKnife.tga"
   ObjectTemplate.AddWeaponIcon "Weapon/Icon_walter.tga"
   ObjectTemplate.AddWeaponIcon "Weapon/Icon_sg44.tga"
   ObjectTemplate.AddWeaponIcon "Weapon/Icon_grenadeaxis.tga"
   ObjectTemplate.SetKitIcon 1 "kits/Icon_assault_axis_selected.tga"
   ObjectTemplate.SetKitName 1 "RESPAWN_ASSAULT"
   ObjectTemplate.SetKitActiveName 1 "RESPAWN_ACTIVE_ASSAULT"
   rem *** The order is important, first the best weapons!
   ObjectTemplate.AddTemplate Sg44
   ObjectTemplate.AddTemplate WalterP38
   ObjectTemplate.AddTemplate KnifeAxis
   ObjectTemplate.AddTemplate GrenadeAxis
   ObjectTemplate.AiTemplate Assault


Go to the ObjectTemplate properties list page, ObjectTemplate page, All Properties list, or Main scripting page.