Arma 3 Scripting

Command in Object Manipulation, Multiplayer

roleDescription

Also available as Markdown and JSON, or read the original wiki page.

Description

Returns unit description set in the editor and visible on role selection screen in multiplayer.

Syntax

roleDescription unit

Parameters:

Returns: String

Examples

Example 1

_playerRole = roleDescription player;

Problems

Does not work in single player.

See also

name · getPlayerUID · vehicleVarName · worldName · briefingName · missionName · serverName

Community notes

Killzone_Kid

One thing you should know about roles. When switching to units placed in editor on the fly in MP, it could mess up the role of the player. Could be bug, could be intended, but I would not recommend doing this. Create new unit dynamically if you need to switch to. Anyway, if role of the unit is messed up so is roleDescription.

Pierre MGI

roleDescription works for playableUnits only. That means not on AI disabled in lobby and not in SP (even for player).