Dynamic Groups – Arma 3
DYNAMIC GROUPS
Installation
To add the Dynamic Groups functionality to your mission do the following steps:
InitServer.sqf
Create a file in your mission root folder and name it initServer.sqf (if you don't have it there already). This file is executed only on the server, when the mission starts. Onto this file, copy & paste the following line, which will make the server initialize the Dynamic Groups framework.
Option 1
Option 2
Note that this function has no effect if called on a machine which is not the server.
InitPlayerLocal.sqf
Create another file in your mission root folder and name it initPlayerLocal.sqf (if you don't have it there already). This file is executed only by machines which have a human player when the mission starts, which means everyone but a dedicated server, will actually execute this file. Onto this file, copy & paste the following line, which will make a client/player initialize the Dynamic Groups framework.
Option 1:
Option 2:
Accessing the Dynamic Groups interface
The Dynamic Groups interface is tied to the TeamSwitch action, and it is default keybind is U.
Additional Functionality
If you would like to register a group manually (same as a player clicking CREATE button in the UI) use RegisterGroup. Please note that the leader you pass, must be the actual leader of the given group, for example:
See BIS_fnc_dynamicGroups in the Functions Viewer for more sub-functions and their parameters.