tmf:assigngear

This is an old revision of the document!


Assign gear is the name of the feature that handles gear assignment. We do not support using arsenal loadouts for players. This is because it is tedious to hand craft for each player and has often in the past been bugged.

The assigngear system makes use of faction configs. These configs can either be in a mission or included in the modpack. Every faction config contains a bunch of different roles (e.g. Squad Leader/Rifleman). You can then give these roles to particular units.

Firstly in Eden on any soldier you use the assign gear component by right clicking on them and clicking on attributes. You will find the following section. This menu will automatically will up roles defined in the modpack or in the mission file.

tmf_assigngear.jpg

To add more or tweak the factions available in a mission you need to open the file description.ext in the mission folder. There will be a section called 'class CfgLoadouts'

assigngear_loadouts.jpg

Here you can create extra factions. You can also override the default ones. By default BLU_F, OPF_F, IND_F are used for the units in the template so if you change this config all the default units in the template will be changed as well.

Firstly if you want to tweak assigngear the best thing to do is use a text editor that can do syntax highlighting. I would recommend using notepad++. If you wish to create your own the best thing to do is to copy an existing config and modify it.

Config 101

Every role is its own class e.g. 'class baseMan'. Every class has properties with the general pattern of “PROPERTY = VALUE;”. Each of these properities is responsible for different things. For example the 'displayName' property is used as a description for this particular kit so if you use 'displayName = “Rifleman”;' that will set the description of that role to Rifleman. Note there can not be two of the same property in a class.

There are also array properties which take the format of:

PROPERTY[] = {"element1", "element2", ... };"

Class Inheritance

One really nice feature of classes is that can inherit from other classes for example 'class g : r' means that class g inherits from class r. In essence all the properties from r now exist in g with the same value. so 'class g : r {};' would make g exactly the same as r. Any property we now set in g will override the value that is inherited from r. For example:

class g : r { displayName = "Grenadier"; };

g is still the same as r except the displayName has now be changed. This is really useful if for one kit you only want to make small changes.

The last thing you can do with inheritance is specific to array attributes you can use the '+=' operator to append to an inherited array. For example:

class g : {
    linkedItems[] = {"ItemWatch","ItemMap","ItemCompass"};
};
class ftl : g {
    linkedItems[] += {"Rangefinder","ItemGPS"};
}

The linkedItems for ftl are now: “ItemWatch”,“ItemMap”,“ItemCompass”“Rangefinder” and “ItemGPS”

  • tmf/assigngear.1458397436.txt.gz
  • Last modified: 2025/08/04 06:49
  • (external edit)