ORBAT Viewer – Arma 3

From Bohemia Interactive Community
Jump to navigation Jump to search
m (→‎Config: spelling)
m (Some wiki formatting)
Line 3: Line 3:


=== Config ===
=== Config ===
CfgORBAT can be defined in [[configFile]] or [[missionConfigFile]].
CfgORBAT can be defined in [[configFile]] or [[missionConfigFile]].


class CfgORBAT
<syntaxhighlight lang="cpp">
{
class CfgORBAT
class 7thInfantry
{
{
class 7thInfantry
id = 7;       {{codecomment|// Unit ID}}
{
idType = 0;   {{codecomment|// Unit ID type}}
id = 7; // Unit ID
side = "West"; {{codecomment|// Unit side from CfgChainOfCommand >> Sides}}
idType = 0; // Unit ID type
size = "Division"; {{codecomment|// Unit size from CfgChainOfCommand >> Sizes. Displays relevant icon above the Type icon}}
side = "West"; // Unit side from CfgChainOfCommand >> Sides
type = "HQ"; {{codecomment|// Unit type from CfgChainOfCommand >> Types}}
size = "Division"; // Unit size from CfgChainOfCommand >> Sizes. Displays relevant icon above the Type icon
insignia = "\ca\missions_f\data\orbat\7thInfantry_ca.paa"; {{codecomment|// Unit insignia, displayed in ORBAT background and in tooltip}}
type = "HQ"; // Unit type from CfgChainOfCommand >> Types
colorInsignia[] = {0,0,1,1}; {{codecomment|// Insignia image color (white default), can be either RGBA array, or class from CfgMarkerColors}}
insignia = "\ca\missions_f\data\orbat\7thInfantry_ca.paa"; // Unit insignia, displayed in ORBAT background and in tooltip
commander = "Armstrong"; {{codecomment|// Name of unit commander. Can be either direct name, or class from CfgWorlds >> GenericNames (random name from the list is then selected)}}
colorInsignia[] = {0,0,1,1}; // Insignia image color (white default), can be either RGBA array, or class from CfgMarkerColors
commanderRank = "GENERAL"; {{codecomment|// Rank of unit commander (by default selected based on unit size)}}
commander = "Armstrong"; // Name of unit commander. Can be either direct name, or class from CfgWorlds >> GenericNames (random name from the list is then selected)
tags[] = {BIS,USArmy,Kerry,Hutchison,Larkin}; {{codecomment|// Group tags. When opening ORBAT viewer, user can define what tags will be accepted.}}
commanderRank = "GENERAL"; // Rank of unit commander (by default selected based on unit size)
text = "%1 Combat Technology Research %3"; {{codecomment|// Custom text and short text, can still use some arguments when defined:}}
tags[] = {BIS,USArmy,Kerry,Hutchison,Larkin}; // Group tags. When opening ORBAT viewer, user can define what tags will be accepted.
{{codecomment|// %1 - ID (e.g. "7th")}}
text = "%1 Combat Technology Research %3"; // Custom text and short text, can still use some arguments when defined:
{{codecomment|// %2 - Type (e.g. "Infantry")}}
// %1 - ID (e.g. "7th")
{{codecomment|// %3 - Size (e.g. "Division")}}
// %2 - Type (e.g. "Infantry")
textShort = "%1 CTR %3";
// %3 - Size (e.g. "Division")
texture = "\ca\missions_f\data\orbat\customTexture_ca.paa"; {{codecomment|// Custom texture, will replace icon set by 'type' param.}}
textShort = "%1 CTR %3";
color[] = {0,0,1,1}; {{codecomment|// Custom color, will replace color set by 'side' param. Can be either RGBA array, or class from CfgMarkerColors}}
texture = "\ca\missions_f\data\orbat\customTexture_ca.paa"; // Custom texture, will replace icon set by 'type' param.
description= "All of your text would go here."; {{codecomment|// A brief description of the group or unit.}}
color[] = {0,0,1,1}; // Custom color, will replace color set by 'side' param. Can be either RGBA array, or class from CfgMarkerColors
assets[] = {{B_Heli_Transport_03_F,5},{B_Heli_Light_01_F,3},{B_Heli_Light_01_armed_F,4},B_Heli_Transport_01_camo_F}; {{codecomment|// Will display pictures of all available assets to the unit commander:}}
description= "All of your text would go here."; // A brief description of the group or unit.
{{codecomment|// Can be an array with format {classname, [int active icons], [int greyed out icons]}, or simply a classname}}
assets[] = {{B_Heli_Transport_03_F,5},{B_Heli_Light_01_F,3},{B_Heli_Light_01_armed_F,4},B_Heli_Transport_01_camo_F}; // Will display pictures of all available assets to the unit commander:
subordinates[] = {2ndBCT}; {{codecomment|// Subordinates, searched on the same level as this class.}}
// Can be an array with format {classname, [int active icons], [int greyed out icons]}, or simply a classname
subordinates[] = {2ndBCT}; // Subordinates, searched on the same level as this class.
  
  
{{codecomment|// When 'subordinates' are missing, child classes will be used. They can have their own subs - number of tiers is not limited.}}
// When 'subordinates' are missing, child classes will be used. They can have their own subs - number of tiers is not limited.
class 1stBCT
class 1stBCT
{
{
id = 1;
id = 1;
type = "Armored";
type = "Armored";
size = "BCT";
size = "BCT";
side = "West";
side = "West";
commander = "NATOMen";
commander = "NATOMen";
tags[] = {"BLUFOR", "USArmy","Kerry"};
tags[] = {"BLUFOR", "USArmy","Kerry"};
   };
   };
};
};
class 2ndBCT
class 2ndBCT
{
{
};
};
};
};
</syntaxhighlight>


=== Valid Attributes ===
=== Valid Attributes ===
<spoiler>__NOTOC__
==== ID Type ====
==== ID Type ====
<spoiler>
* 0 - Ordinal number, e.g. "7th" (default)
*0 - Ordinal number, e.g. "7th" (default)
* 1 - Roman numeral, e.g. "VII"
*1 - Roman numeral, e.g. "VII"
* 2 - NATO phonetical alphabet word, e.g. "Golf"
*2 - NATO phonetical alphabet word, e.g. "Golf"
* 3 - Color, e.g. "Red"
*3 - Color, e.g. "Red"
</spoiler>




==== Side ====
==== Side ====
<spoiler>
* West
* West
* East
* East
Line 64: Line 66:
* Civilian
* Civilian
* Unknown
* Unknown
</spoiler>


==== Size ====
==== Size ====
<spoiler>
* Army
* Army
* ArmyGroup
* ArmyGroup
Line 85: Line 85:
* Squadron
* Squadron
* Troop
* Troop
* Size1->11 (Ex, Size1 [Will not display an size-icon indicator, such as Ø])
* Size1..11 (Ex, Size1 [Will not display an size-icon indicator, such as Ø])
</spoiler>


==== Type ====
==== Type ====
<spoiler>
* Airborne
* Airborne
* Armored
* Armored
Line 114: Line 112:
* UAV
* UAV
* Unknown
* Unknown
</spoiler>


==== Rank ====
==== Rank ====
<spoiler>
* Private
* Private
* Corporal
* Corporal
Line 126: Line 122:
* Colonel
* Colonel
* General
* General
</spoiler>


==== Tags ====
==== Tags ====
Tags are used by [[BIS_fnc_ORBATOpen]]. The function will search and classes with given tags.
Tags are used by [[BIS_fnc_ORBATOpen]]. The function will search and classes with given tags.
</spoiler>


=== ORBAT Group Module ===
=== ORBAT Group Module ===
[[File:A3 ORBATGroup Module.jpg|thumb|left|500px]]
[[File:A3 ORBATGroup Module.jpg|thumb|right|400px]]


==== CfgORBAT Path ====
==== CfgORBAT Path ====
Line 138: Line 134:


'''Example:'''
'''Example:'''
{{Inline code|[[missionConfigFile]] >> "CfgORBAT" >> "unitClassName" >> "subordinateUnitClassName"}}
[[missionConfigFile]] >> "CfgORBAT" >> "unitClassName" >> "subordinateUnitClassName"


==== CfgORBAT Ceiling ====
==== CfgORBAT Ceiling ====
Line 144: Line 140:


'''Example:'''
'''Example:'''
{{Inline code|[[missionConfigFile]] >> "CfgORBAT" >> "unitClassName"}}
[[missionConfigFile]] >> "CfgORBAT" >> "unitClassName"


=== Tags ===
=== Tags ===
Line 157: Line 153:
* Syncronize the module with the group leader
* Syncronize the module with the group leader
* Open the module and fill in the following:
* Open the module and fill in the following:
**CfgORBAT Path: configfile >> "CfgORBAT" >> "BIS" >> "B_1_A_1_2"
** CfgORBAT Path: [[configfile]] >> "CfgORBAT" >> "BIS" >> "B_1_A_1_2"
**CfgORBATCeiling: configfile >> "CfgORBAT" >> "BIS" >> "B_1"
** CfgORBATCeiling: [[configfile]] >> "CfgORBAT" >> "BIS" >> "B_1"
* Leave '''Max. Tiers''' and '''Tags''' empty
* Leave '''Max. Tiers''' and '''Tags''' empty
* Enter the preview mode and open the map
* Enter the preview mode and open the map


==== Texture in missonConfigFile ====
==== Texture in missonConfigFile ====
As '''texture''' is treated as a ''new'' texture (rather than an image, as icon is), Arma needs a direct path to it. Example,
As '''texture''' is treated as a ''new'' texture (rather than an image, as icon is), Arma needs a direct path to it. Example:
<code>C:\Users\Kerry\Documents\Arma 3\Kerry\missions\MyMission.Stratis</code>
<code>C:\Users\Kerry\Documents\Arma 3\Kerry\missions\MyMission.Stratis</code>


However, as {{Inline code|CfgORBAT}} is defined in {{Inline code|description.ext}}, we cannot use SQF scripting like [[missionConfigFile]].
However, as <tt>CfgORBAT</tt> is defined in [[Description.ext]], we cannot use SQF scripting like [[missionConfigFile]];
But we can define a global variable in description.ext using [[PreProcessor Commands]] to our mission's folder. In this case, {{Inline code|MISSIONLOCATION}}.  
we can still define a variable in [[Description.ext]] using [[PreProcessor Commands]] to our mission's folder. In this case, <tt>MISSIONLOCATION</tt>.
<syntaxhighlight lang="cpp">__EXEC (MISSIONLOCATION = __FILE__ select [0, count __FILE__ - 15])</syntaxhighlight>


<code>__EXEC (MISSIONLOCATION = __FILE__ select [0, count __FILE__ - 15])</code>
In our CfgORBAT, be it in a separate <tt>.hpp</tt> file or your description.ext, we can now define the path to our texture with the following:
<syntaxhighlight lang="cpp">texture = __EVAL(MISSIONLOCATION + "someFolder\SomeImage.paa");</syntaxhighlight>


In our CfgORBAT, be it in a separate {{Inline code|.hpp}} file or your description.ext, we can now define the path to our texture with the following:
==== Functions ====
* [[BIS_fnc_ORBATAddGroupOverlay]]
* [[BIS_fnc_ORBATAnimate]]
* [[BIS_fnc_ORBATConfigPreview]]
* [[BIS_fnc_ORBATGetGroupParams]]
* [[BIS_fnc_ORBATOpen]]
* [[BIS_fnc_ORBATRemoveGroupOverlay]]
* [[BIS_fnc_ORBATSetGroupFade]]
* [[BIS_fnc_ORBATSetGroupParams]]
* [[BIS_fnc_ORBATTooltip]]


<code>texture = __EVAL(MISSIONLOCATION + "someFolder\SomeImage.paa");</code>
=== Other ===


==== Functions ====
* [https://forums.bohemia.net/forums/topic/159943-request-orbat-tutorial/?page=3 Various information about ORBAT Viewer]
*[[BIS_fnc_ORBATAddGroupOverlay]]
*[[BIS_fnc_ORBATAnimate]]
*[[BIS_fnc_ORBATConfigPreview]]
*[[BIS_fnc_ORBATGetGroupParams]]
*[[BIS_fnc_ORBATOpen]]
*[[BIS_fnc_ORBATRemoveGroupOverlay]]
*[[BIS_fnc_ORBATSetGroupFade]]
*[[BIS_fnc_ORBATSetGroupParams]]
*[[BIS_fnc_ORBATTooltip]]


=== Other ===
*[http://killzonekid.com/arma-scripting-tutorials-mission-root/ Mission Root Tutorial]
*[https://forums.bohemia.net/forums/topic/159943-request-orbat-tutorial/?page=3 Various information about ORBAT Viewer]


[[Category:Arma 3: Editing]]
[[Category:Arma 3: Editing]]

Revision as of 18:35, 23 April 2020

Template:SideTOC A3 ORBATViewer.jpg

Config

CfgORBAT can be defined in configFile or missionConfigFile.

class CfgORBAT
{
	class 7thInfantry
	{
		id = 7;		// Unit ID
		idType = 0;	// Unit ID type
		side = "West"; // Unit side from CfgChainOfCommand >> Sides
		size = "Division"; // Unit size from CfgChainOfCommand >> Sizes. Displays relevant icon above the Type icon
		type = "HQ"; // Unit type from CfgChainOfCommand >> Types
		insignia = "\ca\missions_f\data\orbat\7thInfantry_ca.paa"; // Unit insignia, displayed in ORBAT background and in tooltip
		colorInsignia[] = {0,0,1,1}; // Insignia image color (white default), can be either RGBA array, or class from CfgMarkerColors
		commander = "Armstrong"; // Name of unit commander. Can be either direct name, or class from CfgWorlds >> GenericNames (random name from the list is then selected)
		commanderRank = "GENERAL"; // Rank of unit commander (by default selected based on unit size)
		tags[] = {BIS,USArmy,Kerry,Hutchison,Larkin}; // Group tags. When opening ORBAT viewer, user can define what tags will be accepted.
		text = "%1 Combat Technology Research %3"; // Custom text and short text, can still use some arguments when defined:
		// %1 - ID (e.g. "7th")
		// %2 - Type (e.g. "Infantry")
		// %3 - Size (e.g. "Division")
		textShort = "%1 CTR %3";
		texture = "\ca\missions_f\data\orbat\customTexture_ca.paa"; // Custom texture, will replace icon set by 'type' param.
		color[] = {0,0,1,1}; // Custom color, will replace color set by 'side' param. Can be either RGBA array, or class from CfgMarkerColors
		description= "All of your text would go here."; // A brief description of the group or unit.
		assets[] = {{B_Heli_Transport_03_F,5},{B_Heli_Light_01_F,3},{B_Heli_Light_01_armed_F,4},B_Heli_Transport_01_camo_F}; // Will display pictures of all available assets to the unit commander:
	 	// Can be an array with format {classname, [int active icons], [int greyed out icons]}, or simply a classname
		subordinates[] = {2ndBCT}; // Subordinates, searched on the same level as this class.
  		
		// When 'subordinates' are missing, child classes will be used. They can have their own subs - number of tiers is not limited.
		class 1stBCT
		{
			id = 1;
			type = "Armored";
			size = "BCT";
			side = "West";
			commander = "NATOMen";
			tags[] = {"BLUFOR", "USArmy","Kerry"};
  		};
	};
	class 2ndBCT
	{
	};
};

Valid Attributes

ID Type

  • 0 - Ordinal number, e.g. "7th" (default)
  • 1 - Roman numeral, e.g. "VII"
  • 2 - NATO phonetical alphabet word, e.g. "Golf"
  • 3 - Color, e.g. "Red"


Side

  • West
  • East
  • Resistance
  • Civilian
  • Unknown

Size

  • Army
  • ArmyGroup
  • Battalion
  • BCT
  • Brigade
  • Company
  • Corps
  • Division
  • FireTeam
  • HBCT
  • IBCT
  • Platoon
  • Regiment
  • Section
  • Squad
  • Squadron
  • Troop
  • Size1..11 (Ex, Size1 [Will not display an size-icon indicator, such as Ø])

Type

  • Airborne
  • Armored
  • Artillery
  • Assault
  • AttackRecon
  • AviationSupport
  • Cavalry
  • CombatAviation
  • Fighter
  • GeneralSupport
  • Helicopter
  • HQ
  • Infantry
  • Maintenance
  • Maritime
  • MechanizedInfantry
  • Medical
  • Mortar
  • MotorizedInfantry
  • Recon
  • Service
  • Support
  • UAV
  • Unknown

Rank

  • Private
  • Corporal
  • Sergeant
  • Lieutenant
  • Captain
  • Major
  • Colonel
  • General

Tags

Tags are used by BIS_fnc_ORBATOpen. The function will search and classes with given tags.

↑ Back to spoiler's top

ORBAT Group Module

A3 ORBATGroup Module.jpg

CfgORBAT Path

The group you want to be display on the map.

Example:

missionConfigFile >> "CfgORBAT" >> "unitClassName" >> "subordinateUnitClassName"

CfgORBAT Ceiling

The highest superior unit to display in the ORBAT Viewer while this group is selected. If blank, the CfgORBAT Path unit is displayed as the ceiling.

Example:

missionConfigFile >> "CfgORBAT" >> "unitClassName"

Tags

Groups containing at least on of these tags will be added

Max. Tiers

Defines how many tiers are are shown.

Working Example

  • Place a fire team in Eden Editor
  • Place the ORBAT Group module
  • Syncronize the module with the group leader
  • Open the module and fill in the following:
    • CfgORBAT Path: configfile >> "CfgORBAT" >> "BIS" >> "B_1_A_1_2"
    • CfgORBATCeiling: configfile >> "CfgORBAT" >> "BIS" >> "B_1"
  • Leave Max. Tiers and Tags empty
  • Enter the preview mode and open the map

Texture in missonConfigFile

As texture is treated as a new texture (rather than an image, as icon is), Arma needs a direct path to it. Example: C:\Users\Kerry\Documents\Arma 3\Kerry\missions\MyMission.Stratis

However, as CfgORBAT is defined in Description.ext, we cannot use SQF scripting like missionConfigFile; we can still define a variable in Description.ext using PreProcessor Commands to our mission's folder. In this case, MISSIONLOCATION.

__EXEC (MISSIONLOCATION = __FILE__ select [0, count __FILE__ - 15])

In our CfgORBAT, be it in a separate .hpp file or your description.ext, we can now define the path to our texture with the following:

texture = __EVAL(MISSIONLOCATION + "someFolder\SomeImage.paa");

Functions

Other