Arma 3 Scripting

Function in Systems

BIS_fnc_missionSelector

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

Description

Function that draws clickable, hoverable and animated icons on the map that execute a user-defined code when pressed.

Syntax

[area, mapCenter, missionsArray] call BIS_fnc_missionSelector

Parameters:

Returns: Number - index of the chosen mission

Examples

Example 1

private _area = [750, 400];
private _missionsList =
[
    [
        getMarkerPos "BIS_briefMarkerINFANTRY",
        "Infantry",
        "Your mission is to do stuff",
        "AnimBriefing\intro_stage1a_CA.paa",
        { hint "infantry mission selected" }
    ],
    [
        getMarkerPos "BIS_briefMarkerSPECIALFORCES",
        "Special Forces",
        "Your mission is to do stuff but in a more special way",
        "AnimBriefing\intro_stage1a_CA.paa",
        { hint "special forces mission selected" }
    ]
];

private _index = [_area, getMarkerPos "BIS_cameraCenter", _missionsList] call BIS_fnc_missionSelector;
private _missionDetails = _missionsList select _index;

See also

playMission