CfgWeapons Config Reference: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
mNo edit summary
Line 10: Line 10:


cfgWepaons define the rifle (eg) characterstics. What muzzles it has, how many 'modes' (if any) it can use. What magazines are selectable.
cfgWepaons define the rifle (eg) characterstics. What muzzles it has, how many 'modes' (if any) it can use. What magazines are selectable.
----
Default values are shown in the legend.


Note that engines will accept integer values (or math strings) where a float would normally be expected.
TokenNames marked '''[[ArmaTokenNames|ArmA]]''' were introduced from Xbox Elite and beyond.


==Arma Enhancement==
==Arma Enhancement==
Line 74: Line 69:




=TokenNames=
----
Default values are shown in the legend.


Note that engines will accept integer values (or math strings) where a float would normally be expected.


TokenNames marked '''[[ArmaTokenNames|ArmA]]''' were introduced from Xbox Elite and beyond.
==A==


=A=
===access=3===
 
==access=3==
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:'''  
'''Description:'''  
Line 88: Line 86:
#define ReadOnlyVerified 3 //! no modifications enabled, CRC test applied
#define ReadOnlyVerified 3 //! no modifications enabled, CRC test applied


==aiDispersionCoefX=1.0==
===aiDispersionCoefX=1.0===
[[TokenNameValueTypes|Float]]<br>
[[TokenNameValueTypes|Float]]<br>
'''Description:''' Dispersion  multiplier for Ai units (axis X - left to right)
'''Description:''' Dispersion  multiplier for Ai units (axis X - left to right)
Line 94: Line 92:
  aiDispersionCoefX = 7.1;
  aiDispersionCoefX = 7.1;


==aiDispersionCoefY=1.0==
===aiDispersionCoefY=1.0===
[[TokenNameValueTypes|Float]]<br>
[[TokenNameValueTypes|Float]]<br>
'''Description:''' Dispersion multiplier for Ai units (axis Y - top-down)
'''Description:''' Dispersion multiplier for Ai units (axis Y - top-down)
Line 100: Line 98:
  aiDispersionCoefY = 2.1;
  aiDispersionCoefY = 2.1;


==aiRateOfFire=5.0==
===aiRateOfFire=5.0===
[[TokenNameValueTypes|Float]]<br>
[[TokenNameValueTypes|Float]]<br>
'''Description:''' delay between shots at given distance (aiRateOfFireDistance)  
'''Description:''' delay between shots at given distance (aiRateOfFireDistance)  
Line 106: Line 104:
  aiRateOfFire = 0.3;
  aiRateOfFire = 0.3;


==aiRateOfFireDistance=500==
===aiRateOfFireDistance=500===
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:''' at shorter distance delay (aiRateOfFire) goes lineary to zero
'''Description:''' at shorter distance delay (aiRateOfFire) goes lineary to zero
Line 112: Line 110:
  aiRateOfFireDistance = 600;
  aiRateOfFireDistance = 600;


==ammo=""==
===ammo=""===
[[TokenNameValueTypes|String]]<br>
[[TokenNameValueTypes|String]]<br>
'''Description:''' Ofp Only. CfgAmmo class that this weapon fires. In ArmA, declared in [[CfgMagazines]] instead.
'''Description:''' Ofp Only. CfgAmmo class that this weapon fires. In ArmA, declared in [[CfgMagazines]] instead.
Line 118: Line 116:
  ammo = "TimeBomb";
  ammo = "TimeBomb";


==autoAimEnabled=true==
===autoAimEnabled=true===
[[TokenNameValueTypes|Boolean]]<br>
[[TokenNameValueTypes|Boolean]]<br>
'''Description:''' FALSE for all standard weapons     
'''Description:''' FALSE for all standard weapons     




==autoFire=false==
===autoFire=false===
[[TokenNameValueTypes|Boolean]]<br>
[[TokenNameValueTypes|Boolean]]<br>
'''Description:''' If true weapon will continue firing once you press fire button once until you release it.
'''Description:''' If true weapon will continue firing once you press fire button once until you release it.




==autoReload=true==
===autoReload=true===
[[TokenNameValueTypes|Boolean]]<br>
[[TokenNameValueTypes|Boolean]]<br>
'''Description:''' if true weapon will be reloaded automaticly once magazine is empty
'''Description:''' if true weapon will be reloaded automaticly once magazine is empty




=B=
==B==


==backgroundReload=false==
===backgroundReload=false===
[[TokenNameValueTypes|Boolean]]<br>
[[TokenNameValueTypes|Boolean]]<br>
'''Description:''' Weapon automatically reloads magazines without player intervention or animation.
'''Description:''' Weapon automatically reloads magazines without player intervention or animation.


==ballisticsComputer=false==
===ballisticsComputer=false===
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Boolean]]<br>
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Boolean]]<br>
'''Description:''' Weapon attempts to calculate and shift the aimpoint to hit a locked target based on range, target movement, own movement, and ballistics of selected ammo type.
'''Description:''' Weapon attempts to calculate and shift the aimpoint to hit a locked target based on range, target movement, own movement, and ballistics of selected ammo type.




==burst=1==
===burst=1===
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:''' Number of shots actually fired each time the weapon is fired.
'''Description:''' Number of shots actually fired each time the weapon is fired.
Line 150: Line 148:
  burst = 5;
  burst = 5;


=C=
==C==


==cameraDir==
===cameraDir===
[[TokenNameValueTypes|String]]<br>
[[TokenNameValueTypes|String]]<br>
'''Description:'''  
'''Description:'''  
Line 158: Line 156:
  cameraDir = "GL look";
  cameraDir = "GL look";


==canDrop=true==
===canDrop=true===
[[TokenNameValueTypes|Boolean]]<br>
[[TokenNameValueTypes|Boolean]]<br>
'''Description:''' Weapon cannot be dropped from Inventory Menu with this set to '''false'''.  
'''Description:''' Weapon cannot be dropped from Inventory Menu with this set to '''false'''.  


==canLock=2==
===canLock=2===
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:''' Defines if weapon can be locked on the target (white box appears)
'''Description:''' Defines if weapon can be locked on the target (white box appears)
Line 171: Line 169:




==cartridgePos="nabojnicestart"==
===cartridgePos="nabojnicestart"===
[[TokenNameValueTypes|String]]<br>
[[TokenNameValueTypes|String]]<br>
'''Description:'''  
'''Description:'''  
==cartridgeVel="nabojniceend"==
===cartridgeVel="nabojniceend"===
[[TokenNameValueTypes|String]]<br>
[[TokenNameValueTypes|String]]<br>
'''Description:'''  
'''Description:'''  


==count=0==
===count=0===
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:''' Number of shots weapon starts with. In ArmA, it is standard to define this in [[CfgMagazines]] instead.
'''Description:''' Number of shots weapon starts with. In ArmA, it is standard to define this in [[CfgMagazines]] instead.
Line 184: Line 182:
  count = 8;
  count = 8;


==cursor==
===cursor===
[[TokenNameValueTypes|String]]<br>
[[TokenNameValueTypes|String]]<br>
'''Description:'''  
'''Description:'''  
Line 190: Line 188:
  cursor = ""; //arma
  cursor = ""; //arma


==cursorAim==
===cursorAim===
[[TokenNameValueTypes|String]]<br>
[[TokenNameValueTypes|String]]<br>
'''Description:'''  
'''Description:'''  
Line 197: Line 195:


  cursorAim = "\ca\Weapons\Data\cursor_target_locked_ca.paa";
  cursorAim = "\ca\Weapons\Data\cursor_target_locked_ca.paa";
==cursorAimOn=""==
===cursorAimOn=""===
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|String]]<br>
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|String]]<br>
'''Description:'''  
'''Description:'''  




==cursorSize=1.0==
===cursorSize=1.0===
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Float]]<br>
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Float]]<br>
'''Description:'''  
'''Description:'''  
Line 208: Line 206:
  cursorSize = 4;
  cursorSize = 4;


=D=
==D==


==dexterity??==
===dexterity??===
[[TokenNameValueTypes|Float]]<br>
[[TokenNameValueTypes|Float]]<br>
'''Description:''' Ingame weapon handling value, lower value = takes more time to traverse a weapon
'''Description:''' Ingame weapon handling value, lower value = takes more time to traverse a weapon
Line 216: Line 214:
  dexterity = 3.1;
  dexterity = 3.1;


==dispersion=0.002==
===dispersion=0.002===
[[TokenNameValueTypes|Float]]<br>
[[TokenNameValueTypes|Float]]<br>
'''Description:''' Ingame weapon dispersion. Bigger value - more dispersion
'''Description:''' Ingame weapon dispersion. Bigger value - more dispersion


==displayName""==
===displayName=""===
[[TokenNameValueTypes|String]]
*Name of the WEAPON
*Name of the MODE
 
A 'displayname' exists for the weapon and is shown in a)gear selection and b) when selecting the weapon in game.
 
A separate 'displayname' exists for each of the weapon's modes (if any)
 
A weapon that only has a single mode *normally* has the same displayname, repeated in the mode class.
 
 
====displayNameMagazine=""(ofp only)====
[[TokenNameValueTypes|String]]<br>
[[TokenNameValueTypes|String]]<br>
'''Description:''' Name of the WEAPON. Either reference to a stringtable, or the name, i.e "Vikhr".
As the name implies, it is the 'displayname' of the magazine and shown when a) reloading a magazine, b) in gear selection.
displayName = "$STR_DN_VIKHR";
 
replaced in Arma via the [[CfgMagazines Config Reference|cfgMagazines Class]]
 


==displayNameMagazine=""==
====shortNameMagazine=""(ofp only)====
OFP Only
[[TokenNameValueTypes|String]]<br>
replaced in Arma via the cfgMazines class
see  shortNameMagazine also


==distanceZoomMax=400==
The ammo descriptive name in cfgAmmo. Replaced in Arma by ShortName in the [[CfgMagazines Config Reference|cfgMagazines Class]]
 
 
===distanceZoomMax=400===
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:'''  
'''Description:'''  
==distanceZoomMin=400==
===distanceZoomMin=400===
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:'''  
'''Description:'''  


==descriptionShort=""==
===descriptionShort=""===


'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|String]]<br>
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|String]]<br>
Line 244: Line 257:




==drySound[]={"",1,1}==
===drySound[]={"",1,1}===
[[TokenNameValueTypes|Array]]<br>
[[TokenNameValueTypes|Array]]<br>
'''Description:''' click Sound  when empty weapon fired
'''Description:''' click Sound  when empty weapon fired
Line 250: Line 263:
  drySound[] = {"\ca\Weapons\Data\Sound\XMS_dry_v2",0.000316228,1};
  drySound[] = {"\ca\Weapons\Data\Sound\XMS_dry_v2",0.000316228,1};


=E=
==E==


==enableAttack=true==
===enableAttack=true===
[[TokenNameValueTypes|Boolean]]<br>
[[TokenNameValueTypes|Boolean]]<br>
'''Description:'''  
'''Description:'''  
==emptySound[]={"",1,1}==
===emptySound[]={"",1,1}===
'''[[ArmaTokenNames|ArmA]]'''  
'''[[ArmaTokenNames|ArmA]]'''  


=F=
==F==


==ffCount=1==
===ffCount=1===
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:'''  
'''Description:'''  
Line 266: Line 279:
  ffCount = 6;
  ffCount = 6;


==ffFrequency=1==
===ffFrequency=1===
[[TokenNameValueTypes|Float]]<br>
[[TokenNameValueTypes|Float]]<br>
'''Description:'''  
'''Description:'''  
Line 272: Line 285:
  ffFrequency = 11;
  ffFrequency = 11;


==ffMagnitude=0==
===ffMagnitude=0===
[[TokenNameValueTypes|Float]]<br>
[[TokenNameValueTypes|Float]]<br>
'''Description:'''  
'''Description:'''  
Line 278: Line 291:
  ffMagnitude = 0.5;
  ffMagnitude = 0.5;


==fireLightDuration=0.05==
===fireLightDuration=0.05===
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Float]]<br>
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Float]]<br>
'''Description:'''  
'''Description:'''  
==fireLightIntensity=0.012==
===fireLightIntensity=0.012===
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Float]]<br>
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Float]]<br>
'''Description:'''  
'''Description:'''  




==flash=""==
===flash=""===
[[TokenNameValueTypes|String]]<br>
[[TokenNameValueTypes|String]]<br>
'''Description:'''  
'''Description:'''  
Line 292: Line 305:
  flash = "gunfire";
  flash = "gunfire";


==flashSize=0==
===flashSize=0===
[[TokenNameValueTypes|Float]]<br>
[[TokenNameValueTypes|Float]]<br>
'''Description:'''  
'''Description:'''  
Line 298: Line 311:
  flashSize = 1.2;
  flashSize = 1.2;


==forceOptics=0==
===forceOptics=0===
[[TokenNameValueTypes|Integer]]<br>
[[TokenNameValueTypes|Integer]]<br>
'''Description:''' Valid values: 0, 1, 2
'''Description:''' Valid values: 0, 1, 2
Line 304: Line 317:
  forceOptics = 2;
  forceOptics = 2;


=G=
==G==


=H=
=H=
Line 358: Line 371:
  magazines[] = {"this"};//ofp
  magazines[] = {"this"};//ofp
  magazines[] = {};//arma
  magazines[] = {};//arma
==magazineType=0==
[[TokenNameValueTypes|Integer]] (enumerated)<br>
OFP only
This value is replaced in ARMA by cfgMagazines.Type=0;




Line 589: Line 596:
'''Description:''' Some modes defined for Ai usage (ex. burst modes for full auto weapons) can be hidden from player with this parameter
'''Description:''' Some modes defined for Ai usage (ex. burst modes for full auto weapons) can be hidden from player with this parameter


==shortNameMagazine=""==
[[TokenNameValueTypes|String]]<br>
Ofp Only
The ammo descriptive name in cfgAmmo, NOT the class
replaced in Arma by ShortName;


==simulation="Weapon";
==simulation="Weapon";
Line 641: Line 643:
  soundServo[] = {"",0.0001,1};
  soundServo[] = {"",0.0001,1};


=T=
==T==
 
===type=WeaponHardMounted(ArmaOnly)===
====magazineType=0(OfpOnly)====
====weaponType=WeaponHardMounted(OfpOnly)====
[[TokenNameValueTypes|Integer]]<br>
 
'''Description:''' Defines the equipment slots this 'weapon' '''OR MAGAZINE''' will occupy
 
OFP does not have a 'Type='. Instead, it uses WeaponType= and MagazineType= couplets. The end result, and the intent, is identical.
 
The naming conventions for this token is misleading. In all cases we are talking about slots available in the equipment (gear) selection. OFP Commented Config confused the issue further by #definining 'types' as weaponslots. They are Weapon,  equipment and Magazine slots.
 
 
A 'vehicle', in this case a human, has it's equipment slots defined in the cfgVehicles Class. In general it consists of placements for:
 
*A 'slot' for a Primary Weapon (rifle eg)
*A 'slot' for a Secondary Weapon (Law Launcher)
** Magazine slots for these weapons (AK47Mag)
*A Handgun slot (Berreta eg)
** Magazine slots for this weapon (CZ75Mag)
* Equipment slots (binoculars)
 
For arma, Magazine 'slots' and Weapon 'slots' are mutually exclusive. They only occur in the cfgWeapons or cfgMagazines respectively
 
The specific combination for machine guns normally occupy both weapon slots (PrimaryWeapon+SecondaryWeapon)
 
Some humans have less slots than others. Arma1 seriously degraded this distinction and destroyed it, An ofp medic (or civilian) cannot hope to carry as much 'equipment'. Many well crafted missions rely on the fact that civilans are not, a 4th army grouping by another name but have distinct (and unique) characterstics.


==type=WeaponHardMounted==
'''[[ArmaTokenNames|ArmA]]''' [[TokenNameValueTypes|Integer]]<br>
'''Description:''' Defines gear slots occupied by this weapon


*Note that OFP uses WeaponType= and MagazineType= as couplets instead of 'Type'
*Note the quite serious an un-necessary alteration to SecondaryWeapon and Handgun mags that occurred in arma
*Note the quite serious alteration to SecondaryWeapon and Handgun mags that occurred in arma
*The specific combination for machine guns normally occupy both weapon slots (PrimaryWeapon+SecondaryWeapon)
*Magazine 'slots' and Weapon 'slots' are mutually exclusive. They only occur in the cfgWeapons or cfgMagazines respectively
-----
-----


Line 676: Line 699:


----
----
===extended bit fields===
====extended bit fields====
specific bit-field identities between 256 and 4096 are frequently represented textually as
specific bit-field identities between 256 and 4096 are frequently represented textually as


Line 721: Line 744:




=W=
 
==weaponType=WeaponHardMounted==
ofp only as per Type in arma
=X=
=X=



Revision as of 16:28, 15 August 2010

Template:Stub

Introduction

CfgAmmo, cfgMagazines, cfgWeapons and cfgVehicles are root classes defined in the engine's config.bin.

These classes can be subsequently added to by addons inherit in the game or provided by oem.

CfgAmmo defines the missile characterstics for ammunition held in a cfgMagazine which, in turn, is used by a cfgWeapon, which, in turn, is selected for use in a (series of) cfgVehicles. The same ammunition can be, and generally is, used by multiple magazines. The same magazine, can be, and generally is, used by multiple weapons. And so on.

cfgWepaons define the rifle (eg) characterstics. What muzzles it has, how many 'modes' (if any) it can use. What magazines are selectable.


Arma Enhancement

Arma introduced a new root class, cfgMagazines.

In contrast, OFP uses a rather tedious construct in it's cfgWeapons class to distinguish between weapon and magazine paramaters.

The major alterations here are:

         OFP           ARMA
ammo=                  moved to cfgMagazines
cost=                  moved to cfgMagazines
displayNameMagazine=   moved to cfgMagazines and renamed DisplayName (of course)
magazines[] = {"this"};magazines[] = {};
magazineType=          moved to cfgMagazines and rennamed Type
maxLeadSpeed=          moved to cfgMagazines
minRange =             moved FROM cfgAmmo
minRangeProbab =
midRange =
midRangeProbab =
maxRange = 
maxRangeProbab = 
scopeWeapon=          renamed scope
scopeMagazine=        moved to cfgMagazines and rennamed scope
shortNameMagazine=    moved to cfgMagazines and rennamed descriptionShort?

Modifications

cfgWeapons {
 access=1;
  • Weapon classes can be added.
  default {
   access=3;
  • Existing classes can (rarely) be altered.

The default class of cfgWeapons specifies access=3; Almost all subsequent classes inherit this value, which means they cannot be altered in any way.

To allow YOUR addon to subsequently modify YOUR weapon (should you wish to with other addons), you must change the access= in YOUR Weapon.

Navigation thu the woods for the trees

CfgWeapons can be a puzzling mess to the un-initiated.

The tokenpairs, their placement, and their constructs can be befuddled. This is not a reflection on bi, the ultimate class structure is very, very, adaptive, but, it does confuse.

  • Essentially, Arma did open heart, and excellent, surgery to this class to distinguish between weapons and their magazines. Ofp had a common weapon/magazine class with variables declaring what to use, when. Variables only relevent to ofp, are sometimes still encountered in arma, simply because, they do no harm.
  • Weapons come in two major flavors (with plenty of subthemes). A weapon either has, or does not have, a modes[] class or classes adding different behaviour like autofire, burst, single shot. Confusingly, a weapon with only one mode, is, equivalent to not declaring it at all. The tokens that would normally be in a modes class, are declared in the main body instead. This obfuscates what-goes-where.
  • Weapons can have different muzzles. adding a further layer of modelling.
  • The inherited tree structure for weapons vs their magazines, vs their ammo, is not always logical. This is a throwback to OFP which (for instance) inherited RPG Ammo from an AT3, but inherited the RPG weapon from a CarlGustav, and so on. The end result being identical and good, since offending paramaters were altered as necessary, but it does confuse what a HellFireHind really is, depending on who you are (ammo vs mag vs weapon)


TokenNames


Default values are shown in the legend.

Note that engines will accept integer values (or math strings) where a float would normally be expected.

TokenNames marked ArmA were introduced from Xbox Elite and beyond.

A

access=3

Integer
Description:

  1. define ReadAndWrite 0 //! any modifications enabled
  2. define ReadAndCreate 1 //! only adding new class members is allowed
  3. define ReadOnly 2 //! no modifications enabled
  4. define ReadOnlyVerified 3 //! no modifications enabled, CRC test applied

aiDispersionCoefX=1.0

Float
Description: Dispersion multiplier for Ai units (axis X - left to right)

aiDispersionCoefX = 7.1;

aiDispersionCoefY=1.0

Float
Description: Dispersion multiplier for Ai units (axis Y - top-down)

aiDispersionCoefY = 2.1;

aiRateOfFire=5.0

Float
Description: delay between shots at given distance (aiRateOfFireDistance)

aiRateOfFire = 0.3;

aiRateOfFireDistance=500

Integer
Description: at shorter distance delay (aiRateOfFire) goes lineary to zero

aiRateOfFireDistance = 600;

ammo=""

String
Description: Ofp Only. CfgAmmo class that this weapon fires. In ArmA, declared in CfgMagazines instead.

ammo = "TimeBomb";

autoAimEnabled=true

Boolean
Description: FALSE for all standard weapons


autoFire=false

Boolean
Description: If true weapon will continue firing once you press fire button once until you release it.


autoReload=true

Boolean
Description: if true weapon will be reloaded automaticly once magazine is empty


B

backgroundReload=false

Boolean
Description: Weapon automatically reloads magazines without player intervention or animation.

ballisticsComputer=false

ArmA Boolean
Description: Weapon attempts to calculate and shift the aimpoint to hit a locked target based on range, target movement, own movement, and ballistics of selected ammo type.


burst=1

Integer
Description: Number of shots actually fired each time the weapon is fired.

burst = 5;

C

cameraDir

String
Description:

cameraDir = "GL look";

canDrop=true

Boolean
Description: Weapon cannot be dropped from Inventory Menu with this set to false.

canLock=2

Integer
Description: Defines if weapon can be locked on the target (white box appears) Valid values: 0, 1, 2

  1. define LockNo 0
  2. define LockCadet 1
  3. define LockYes 2


cartridgePos="nabojnicestart"

String
Description:

cartridgeVel="nabojniceend"

String
Description:

count=0

Integer
Description: Number of shots weapon starts with. In ArmA, it is standard to define this in CfgMagazines instead.

count = 8;

cursor

String
Description:

cursor="w_weapon";// ofp
cursor = ""; //arma

cursorAim

String
Description:

 cursorAim = "w_lock";//ofp
 cursorAim = "";//arma
cursorAim = "\ca\Weapons\Data\cursor_target_locked_ca.paa";

cursorAimOn=""

ArmA String
Description:


cursorSize=1.0

ArmA Float
Description:

cursorSize = 4;

D

dexterity??

Float
Description: Ingame weapon handling value, lower value = takes more time to traverse a weapon

dexterity = 3.1;

dispersion=0.002

Float
Description: Ingame weapon dispersion. Bigger value - more dispersion

displayName=""

String

  • Name of the WEAPON
  • Name of the MODE

A 'displayname' exists for the weapon and is shown in a)gear selection and b) when selecting the weapon in game.

A separate 'displayname' exists for each of the weapon's modes (if any)

A weapon that only has a single mode *normally* has the same displayname, repeated in the mode class.


displayNameMagazine=""(ofp only)

String
As the name implies, it is the 'displayname' of the magazine and shown when a) reloading a magazine, b) in gear selection.

replaced in Arma via the cfgMagazines Class


shortNameMagazine=""(ofp only)

String

The ammo descriptive name in cfgAmmo. Replaced in Arma by ShortName in the cfgMagazines Class


distanceZoomMax=400

Integer
Description:

distanceZoomMin=400

Integer
Description:

descriptionShort=""

ArmA String

This is the equivalent of ofp's ammunition label (shortNameMagazine) and is, strangely, declared in weapons??


drySound[]={"",1,1}

Array
Description: click Sound when empty weapon fired

drySound[] = {"\ca\Weapons\Data\Sound\XMS_dry_v2",0.000316228,1};

E

enableAttack=true

Boolean
Description:

emptySound[]={"",1,1}

ArmA

F

ffCount=1

Integer
Description:

ffCount = 6;

ffFrequency=1

Float
Description:

ffFrequency = 11;

ffMagnitude=0

Float
Description:

ffMagnitude = 0.5;

fireLightDuration=0.05

ArmA Float
Description:

fireLightIntensity=0.012

ArmA Float
Description:


flash=""

String
Description: ofp only?

flash = "gunfire";

flashSize=0

Float
Description: ofp only?

flashSize = 1.2;

forceOptics=0

Integer
Description: Valid values: 0, 1, 2

forceOptics = 2;

G

H

handAnim[] = {}

ArmA Array


I

initSpeed=0

Integer
Description: Initial speed of shot.

initSpeed = 900;

J

K

L

laser=false

ArmA Boolean
Description:


libTextDesc

ArmA String
Description:

libTextDesc = "$STR_LIB_SVD";

Library

ArmA

 class Library
 {
  libTextDesc = "";
 };


M

magazineReloadTime=0

Float
Description: Time delay when reloading the weapon (changing magazines).

magazineReloadTime = 0.1;

magazines[]

Array
Description: Array of magazines compatible with this weapon. In ArmA, these are defined in CfgMagazines. In OFP they are (generally) the same Weapon class.

magazines[] = {"this"};//ofp
magazines[] = {};//arma


maxLeadSpeed=50

Integer
Description: Maximimum speed of the target that can be shot with this weapon by AI. For OFP only, in ArmA this command has only effect in CfgMagazines.

min/mid/maxRange...

Description: Together with *Range and *RangeProbab values defines probability to use this weapon for Ai units at given distance. For OFP these paramaters were specified in cfgAmmo, rendering all rifles the same.

minRange=1

Integer
Description:

minRangeProbab=0.3

Float
Description:

midRange=150

Integer
Description:

midRangeProbab= 0.58

Float
Description:

maxRange=500

Float

maxRangeProbab=0.04

Float
Description:

memoryPointCamera="eye"

ArmA String
Description:

memoryPointCamera = "GL eye";


model="[.p3d]"

String
Description:

model = "\ca\a10\AGM65";


modelMagazine="[.p3d]"

String
Description:

modelMagazine = "\misc\mag_univ.p3d";// ofp
modelMagazine = "";//arma

modelOptics="[.p3d]"

String
Description: Optic model used in game. "-" defines 3d view from the model (point "eye")

modelOptics = "\ca\Weapons\G36_optics";
modelOptics = "-";

modelSpecial=""

String


modes[]= {"this"}

Array
Description:

modes[] = {"manual","close","short","medium","far"};// or anyting you care to claim as a class xxx

if not specified, (modes[]= {"this"};) the engine assumes all parms necessary for A mode, are declared within the main body

multiplier=1

Integer
Description: Ammunition used per shot.

multiplier = 5;

muzzleEnd="konec hlavne"

String
Description:

muzzlePos="usti hlavne"

String
Description:

muzzles[]={"this"}

Array
Description: similar to modes, if not declared, assumed muzzel is 'this'

muzzles[] = {"TimeBombMuzzle","PipeBombMuzzle","MineMuzzle","MineEMuzzle"};

N

nameSound

String
Description: Sound played when vehicle cammander switches to this weapon?

 nameSound = "weapon";//ofp
 nameSound = "";//arma
nameSound = "smokeshell";

O

optics=true

Boolean
Description:

opticsDisablePeripherialVision=0.67

ArmA Float
Description:

opticsFlare=true

Boolean
Description:

opticsPPEffects[] = {}

ArmA Array
Description:

opticsZoomInit= 0.35

Float
Description:

opticsZoomMax=0.35

Float
Description:

opticsZoomMin=0.35

Float
Description:

P

picture="[\][.pac]"

String
Description:

Note that this is one of those irritating bis path snafu's. (when if ever will they start using relative addressing?). The following notes apply to ALL picture= references. Not just cfgWeapons.

  • Firstly, the DEFAULT extension is .pac. (There is not intended to be 'pac' in arma), a .paa must be explicitly declared.
  • Secondly, it must explicitly have a \leading. This, possibly in an attempt by bis to start using relative addressing. Without which, textures are presumed to be in \w_equip\neverland.


primary=10

Integer
Description:

Q

R

recoil="Empty"

String
Description: Selects recoil defined in cfgRecoils class

ArmA differs substantially in Recoil ability. Much more of them, and very different names.
recoil = "AK74Recoil";

recoilProne=""

ArmA String
Description: When prone, recoil can be set to slower values

recoilProne = "AK74Recoil";

reloadAction

Stringenumerated list
Description:

 reloadAction = ManActReloadMagazine;//ofp
 reloadAction = "";//arma

reloadMagazineSound[]={"",1,1}

Array
Description: Sound played while changing magazines.

reloadMagazineSound[] = {"\ca\Weapons\Data\Sound\flare_reload",0.000316228,1};

reloadSound[]={"",1,1}

Array
Description: Sound played after each shot.

reloadSound[] = {"\ca\Weapons\Data\Sound\gun125reload",1,1};

reloadTime=1.0

Float
Description: Time delay between each individual shot.


S

scope=0

ArmA Integer
Description:

Note: Refers to the accessibility of the variable, not a rifle scope.

OFP had no scope token. Instead, it used scopeWeapon and ScopeMagazine to distinction who was what and when used.

scopeWeapon=0

scopeMagazine=0

OFP only used as couplets instead of scope

selectionFireAnim="zasleh"

ArmA String
Description:


shotFromTurret???

ArmA Boolean
Description: meaning unknown. But "zasleh" animation is not working if set to 1

shotFromTurret = 1;

showAimCursorInternal=true

ArmA Boolean
Description:

showEmpty=true

Boolean
Description: If false weapon gets hidden from the player once there's no ammo left for it


showSwitchAction=false

ArmA Boolean
Description:


showToPlayer=true

ArmA Boolean
Description: Some modes defined for Ai usage (ex. burst modes for full auto weapons) can be hidden from player with this parameter


==simulation="Weapon"; ArmA

sound[]={"",1,1}

Array
Description: Last parameter defines how fast the sound should be played. 1 means normal speed.

sound[] = {"\ca\Weapons\Data\Sound\AGS30_shot1",10,1};

soundBurst=true

ArmA Boolean
Description: When set to false single shot sound can be used with burst mode - it will be played several times


soundContinuous=false

Boolean
Description: If true sound for the next shot won't start before previous oe ends. Thus you can prevent sound overlapping.

soundBegin[]={"sound",1}

ArmA Array

soundBullet[]={"emptySound",1}

ArmA Array

soundEnd[]={"sound",1}

ArmA Array

soundLoop[]={"sound",1}

ArmA Array


note that there is extensive use of soundloops in arma. Most weapons elaborate on this basic, essentially ofp, structure with begin1,2,3 loops etc.



soundFly[]??

Array
Description:

soundFly[] = {"\ca\Weapons\Data\Sound\rocket_fly1",25.1189,0.8};

soundServo[]??

Array
Description:

soundServo[] = {"",0.0001,1};

T

type=WeaponHardMounted(ArmaOnly)

magazineType=0(OfpOnly)

weaponType=WeaponHardMounted(OfpOnly)

Integer

Description: Defines the equipment slots this 'weapon' OR MAGAZINE will occupy

OFP does not have a 'Type='. Instead, it uses WeaponType= and MagazineType= couplets. The end result, and the intent, is identical.

The naming conventions for this token is misleading. In all cases we are talking about slots available in the equipment (gear) selection. OFP Commented Config confused the issue further by #definining 'types' as weaponslots. They are Weapon, equipment and Magazine slots.


A 'vehicle', in this case a human, has it's equipment slots defined in the cfgVehicles Class. In general it consists of placements for:

  • A 'slot' for a Primary Weapon (rifle eg)
  • A 'slot' for a Secondary Weapon (Law Launcher)
    • Magazine slots for these weapons (AK47Mag)
  • A Handgun slot (Berreta eg)
    • Magazine slots for this weapon (CZ75Mag)
  • Equipment slots (binoculars)

For arma, Magazine 'slots' and Weapon 'slots' are mutually exclusive. They only occur in the cfgWeapons or cfgMagazines respectively

The specific combination for machine guns normally occupy both weapon slots (PrimaryWeapon+SecondaryWeapon)

Some humans have less slots than others. Arma1 seriously degraded this distinction and destroyed it, An ofp medic (or civilian) cannot hope to carry as much 'equipment'. Many well crafted missions rely on the fact that civilans are not, a 4th army grouping by another name but have distinct (and unique) characterstics.


  • Note the quite serious an un-necessary alteration to SecondaryWeapon and Handgun mags that occurred in arma

Slot: OFP ARMA Example
either: NoSlot 0 0 dummy weapon or mag 'stroke' eg
Weapon: PrimaryWeapon 1 1 AK47
Weapon: HandGun 2 2 CZ75
Weapon: SecondaryWeapon 16 4 Law
Mag: HandGunMagazines 32 16 CZ75Mag or GLMag
Mag: MainMagazines 256 256 AK47Mag or explosives
Weapon: BinocularSlot 4096 4096 or NVG, LD,etc
Weapon: HardMounted 65536 65536
Mag: SmallItems 131072 (Arma 2) map, compass, small items (derived from ItemCore)

extended bit fields

specific bit-field identities between 256 and 4096 are frequently represented textually as

"1 * 256" // main mags
"2 * 256" // m60,pk,mortars,law
"4 * 256" // 6g30
"6 * 256" // carlgustav,stinger
"8 * 256" // mm1

U

UiPicture

String
Description:

 uiPicture = "ivojak";//ofp
uiPicture = "";//arma

UiPicture = "\CA\weapons\data\Ico\i_aa_CA.paa";

useAction=false

Boolean
Description:

useActionTitle=""

String
Description:

useActionTitle = "$STR_ACTION_PUTBOMB";

useAsBinocular=false

Boolean
Description:


V

value=2

ArmA Integer
Description:

valueMagazine = 2

valueWeapon = 2

ofp only as above


X

Y

Z