difficulty

From Bohemia Interactive Community
Revision as of 13:13, 12 March 2024 by Lou Montana (talk | contribs) (Some wiki formatting)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Hover & click on the images for description

Description

Description:
Returns high-level selected difficulty mode.
Groups:
Difficulty

Syntax

Syntax:
difficulty
Return Value:
Number - Can be one of:
  • 0 (Recruit)
  • 1 (Regular)
  • 2 (Veteran)
  • 3 (Elite)

Examples

Example 1:
if (difficulty == 0) then { hint "You will need to follow my lead - read the Field Manual!"; };
Example 2:
Note: "Insane" is a modded difficulty
The command returns the index of selected difficulty as they appear in CfgDifficulties:
hint str difficulty; //Result: 4

Additional Information

See also:
difficultyOption Arma 3: Difficulty Settings missionDifficulty

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note
POLPOX - c
Posted on Aug 22, 2023 - 06:31 (UTC)
The return value can be overwritten by the forcedDifficulty by the server if it is a MP session.