difficultyEnabled: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
No edit summary
m (Text replacement - "(\|[pr][0-9]+ *= *[^-]+) *- *D([a-z])" to "$1 - d$2")
 
(76 intermediate revisions by 14 users not shown)
Line 1: Line 1:
{{Command|= Comments
{{RV|type=command
____________________________________________________________________________________________


| arma |= Game name
|game1= arma1
|version1= 1.05


|1.05|= Game version
|game2= arma2
____________________________________________________________________________________________
|version2= 1.00


| Checks specific difficulty settings of the current user. Difficulty flag names can be found in the ArmA profile file under class Difficulties/xxx/Flags (xxx being regular or veteran). |= Description
|game3= arma2oa
____________________________________________________________________________________________
|version3= 1.50


| [[Boolean]] <nowiki>=</nowiki> '''difficultyEnabled''' "FlagName"|= Syntax
|game4= tkoh
|version4= 1.00


|p1= FlagName: [[String]] - difficulty flag name |= Parameter 1
|game5= arma3
|version5= 0.50


| [[Boolean]] |= Return value
|gr1= Difficulty
____________________________________________________________________________________________
 
|x1= <code>hint str (difficultyEnabled "armor")</code>  |= Example 1
____________________________________________________________________________________________


| |= See also
|descr= Checks specific difficulty settings of the current user. Difficulty flag names can be found in the [[server.armaprofile|ArmA profile]] file under class Difficulties/xxx/Flags (xxx being regular or veteran).


|mp= This command checks the difficulty flags of the computer (client/server) where it is executed.
{{Feature|arma3|
This command is '''deprecated since {{arma3}} v1.58'''. Since this version it always returns false. Use [[difficultyOption]] instead.
See [[Arma 3: Difficulty Settings#Difficulty_Overhaul|Arma 3 Difficulty Overhaul]] for further details.
* Stress damage is a separate difficulty setting. There are two dedicated commands for it:
** [[enableStressDamage]]
** [[isStressDamageEnabled]]
* Auto trim is also a separate difficulty setting. There are also two dedicated commands for it:
** [[enableAutoTrimRTD]]
** [[isAutoTrimOnRTD]]
}}
}}


<h3 style="display:none">Notes</h3>
|s1= [[difficultyEnabled]] flagName
<dl class="command_description">


<!-- Note Section BEGIN -->
|p1= flagName: [[String]] - difficulty flag name. Following values are available:<br>
<spoiler text="Arma 3 Flags">
{{Columns|5|
* 3rdPersonView
* armor
* autoAim
* autoGuideAT
* autoSpot
* autoTrimEnabled
* cameraShake
* clockIndicator
* deathMessages
* enemyTag
* extendetInfoType
* friendlyTag
* hud
* hudGroupInfo
* hudPerm
* hudWp
* hudWpPerm
* map
* mineTag
* netStats
* roughLanding
* stanceIndicator
* stressDamageEnabled
* unlimitedSaves
* vonID
* weaponCursor
* windEnabled
}}
</spoiler>
<spoiler text="Arma 2 Flags">
{{Columns|5|
* 3rdPersonView
* armor
* autoSpot
* autoGuideAT
* autoAim
* allowSeagull
* clockIndicator
* deathMessages
* enemyTag
* friendlyTag
* hud
* hudPerm
* hudWp
* hudWpPerm
* map
* netStats
* suppressPlayer
* tracers
* realisticFatigue
* ultraAI
* unlimitedSaves
* weaponCursor
}}
</spoiler>


----
|r1= [[Boolean]]


CfgDifficulties:
|x1= <sqf>hint str (difficultyEnabled "armor");</sqf>


[S] = String
|x2= List current difficulty settings:
<sqf>
call {
private ["_diff", "_cfg", "_flags", "_res"];
_diff = [];
_cfg = configFile >> "CfgDifficulties";
{
_flags = _cfg >> configName _x >> "Flags";
for "_i" from 0 to count _flags - 1 do {
_diff pushBack configName (_flags select _i);
};
} forEach ("true" configClasses _cfg);
_diff = _diff arrayIntersect _diff;
_diff sort true;
_res = text "";
{
_res = composeText [_res, parseText format [
"<t align='left'>%1 - %2</t>",
_x,
[0, 1] select difficultyEnabled _x
], lineBreak];
} forEach _diff;
hint _res;
};
</sqf>


[C] = Class
|seealso= [[difficultyOption]] [[difficulty]] [[difficultyEnabledRTD]] [[Arma 3: Difficulty Settings]]
 
}}
[N] = Number
 
[A] = Array
 
 
[S] configFile >> CfgDifficulties >> default = Regular
 
[C] configFile >> CfgDifficulties >> Regular =
 
[S] configFile >> CfgDifficulties >> Regular >> displayName = Kadett
 
[C] configFile >> CfgDifficulties >> Veteran =
 
[S] configFile >> CfgDifficulties >> Regular >> description =
 
[S] configFile >> CfgDifficulties >> Veteran >> displayName = Veteran
 
[N] configFile >> CfgDifficulties >> Regular >> showCadetHints = 1
 
[S] configFile >> CfgDifficulties >> Veteran >> description =
 
[N] configFile >> CfgDifficulties >> Regular >> showCadetWP = 1
 
[N] configFile >> CfgDifficulties >> Veteran >> showCadetHints = 0
 
[N] configFile >> CfgDifficulties >> Regular >> maxPilotHeight = 400
 
[N] configFile >> CfgDifficulties >> Veteran >> showCadetWP = 1
 
[S] configFile >> CfgDifficulties >> Regular >> scoreChar = o
 
[N] configFile >> CfgDifficulties >> Veteran >> maxPilotHeight = 10000
 
[S] configFile >> CfgDifficulties >> Regular >> badScoreChar = X
 
[S] configFile >> CfgDifficulties >> Veteran >> scoreChar = *
 
[N] configFile >> CfgDifficulties >> Regular >> skillFriendly = 0.75
 
[S] configFile >> CfgDifficulties >> Veteran >> badScoreChar = X
 
[N] configFile >> CfgDifficulties >> Regular >> skillEnemy = 0.6
 
[N] configFile >> CfgDifficulties >> Veteran >> skillFriendly = 0.85
 
[N] configFile >> CfgDifficulties >> Regular >> myArmorCoef = 3
 
[N] configFile >> CfgDifficulties >> Veteran >> skillEnemy = 0.85
 
[N] configFile >> CfgDifficulties >> Regular >> groupArmorCoef = 2.4
 
[N] configFile >> CfgDifficulties >> Veteran >> myArmorCoef = 1.2
 
[N] configFile >> CfgDifficulties >> Regular >> autoAimSizeFactor = 0.9
 
[N] configFile >> CfgDifficulties >> Veteran >> groupArmorCoef = 1.1
 
[N] configFile >> CfgDifficulties >> Regular >> autoAimDistance = 1.3
 
[N] configFile >> CfgDifficulties >> Veteran >> autoAimSizeFactor = 0.7
 
[N] configFile >> CfgDifficulties >> Regular >> autoAimAngle = 6
 
[N] configFile >> CfgDifficulties >> Veteran >> autoAimDistance = 1
 
[N] configFile >> CfgDifficulties >> Regular >> peripheralVisionAid = 0.9
 
[N] configFile >> CfgDifficulties >> Veteran >> autoAimAngle = 4
 
[N] configFile >> CfgDifficulties >> Regular >> visionAid = 0
 
[N] configFile >> CfgDifficulties >> Veteran >> peripheralVisionAid = 0.6
 
[C] configFile >> CfgDifficulties >> Regular >> Flags =
 
[N] configFile >> CfgDifficulties >> Veteran >> visionAid = 0
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> armor = [1,1]
 
[S] configFile >> CfgDifficulties >> Regular >> scoreImage = \ca\ui\textures\deb_pecka.paa
 
[C] configFile >> CfgDifficulties >> Veteran >> Flags =
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> friendlyTag = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> armor = [0,0]
 
[S] configFile >> CfgDifficulties >> Regular >> badScoreImage = \ca\ui\textures\deb_krizek.paa
 
[S] configFile >> CfgDifficulties >> Veteran >> scoreImage = \ca\ui\textures\deb_hvezdicka.paa
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> enemyTag = [0,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> friendlyTag = [0,0]
 
[S] configFile >> CfgDifficulties >> Veteran >> badScoreImage = \ca\ui\textures\deb_krizek.paa
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> hud = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> enemyTag = [0,0]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> hudPerm = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> hud = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> hudWp = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> hudPerm = [0,0]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> hudWpPerm = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> hudWp = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> autoSpot = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> hudWpPerm = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> map = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> autoSpot = [0,0]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> weaponCursor = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> map = [0,0]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> autoGuideAT = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> weaponCursor = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> clockIndicator = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> autoGuideAT = [0,0]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> 3rdPersonView = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> clockIndicator = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> tracers = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> 3rdPersonView = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> ultraAI = [0,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> tracers = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> autoAim = [0,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> ultraAI = [0,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> unlimitedSaves = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> autoAim = [0,0]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> deathMessages = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> unlimitedSaves = [0,0]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> netStats = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> deathMessages = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> allowSeagull = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> netStats = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> suppressPlayer = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> allowSeagull = [1,1]
 
[A] configFile >> CfgDifficulties >> Regular >> Flags >> realisticFatigue = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> suppressPlayer = [1,1]
 
[A] configFile >> CfgDifficulties >> Veteran >> Flags >> realisticFatigue = [1,1]
 
 
--[[User:Crowe|Crowe]] 16:22, 14 March 2008 (CET)
 
----
 
 
<!-- Note Section END -->
</dl>
 
<h3 style="display:none">Bottom Section</h3>
 
[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands ArmA|{{uc:{{PAGENAME}}}}]]
[[Category:Command_Group:_System_Commands|{{uc:{{PAGENAME}}}}]]

Latest revision as of 15:01, 8 November 2023

Hover & click on the images for description

Description

Description:
Checks specific difficulty settings of the current user. Difficulty flag names can be found in the ArmA profile file under class Difficulties/xxx/Flags (xxx being regular or veteran).
Multiplayer:
This command checks the difficulty flags of the computer (client/server) where it is executed.
Arma 3
This command is deprecated since Arma 3 v1.58. Since this version it always returns false. Use difficultyOption instead.

See Arma 3 Difficulty Overhaul for further details.

Groups:
Difficulty

Syntax

Syntax:
difficultyEnabled flagName
Parameters:
flagName: String - difficulty flag name. Following values are available:
  • 3rdPersonView
  • armor
  • autoAim
  • autoGuideAT
  • autoSpot
  • autoTrimEnabled
  • cameraShake
  • clockIndicator
  • deathMessages
  • enemyTag
  • extendetInfoType
  • friendlyTag
  • hud
  • hudGroupInfo
  • hudPerm
  • hudWp
  • hudWpPerm
  • map
  • mineTag
  • netStats
  • roughLanding
  • stanceIndicator
  • stressDamageEnabled
  • unlimitedSaves
  • vonID
  • weaponCursor
  • windEnabled
  • 3rdPersonView
  • armor
  • autoSpot
  • autoGuideAT
  • autoAim
  • allowSeagull
  • clockIndicator
  • deathMessages
  • enemyTag
  • friendlyTag
  • hud
  • hudPerm
  • hudWp
  • hudWpPerm
  • map
  • netStats
  • suppressPlayer
  • tracers
  • realisticFatigue
  • ultraAI
  • unlimitedSaves
  • weaponCursor
Return Value:
Boolean

Examples

Example 1:
hint str (difficultyEnabled "armor");
Example 2:
List current difficulty settings:
call { private ["_diff", "_cfg", "_flags", "_res"]; _diff = []; _cfg = configFile >> "CfgDifficulties"; { _flags = _cfg >> configName _x >> "Flags"; for "_i" from 0 to count _flags - 1 do { _diff pushBack configName (_flags select _i); }; } forEach ("true" configClasses _cfg); _diff = _diff arrayIntersect _diff; _diff sort true; _res = text ""; { _res = composeText [_res, parseText format [ "<t align='left'>%1 - %2</t>", _x, [0, 1] select difficultyEnabled _x ], lineBreak]; } forEach _diff; hint _res; };

Additional Information

See also:
difficultyOption difficulty difficultyEnabledRTD Arma 3: Difficulty Settings

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