Difference between revisions of "Arma 3: AI Skill"

From Bohemia Interactive Community
Jump to navigation Jump to search
m (changed category)
m (Text replacement - "\[ *(https?\:\/\/[^\[ ]+\.bohemia\.net[^\[]+) ([^ ]+) *\]" to "{{ExternalLink|link= $1|text= $2}}")
 
(56 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
{{Feature|Informative|Some information on this page were not confirmed by BIS!}}
 
[[Category:AI]]
 
[[Category:AI]]
[[Category: Arma 3: Editing]]
 
  
 
[[File:AI_skill_and_level.png|thumb|AI skill/level/final skill]]
 
[[File:AI_skill_and_level.png|thumb|AI skill/level/final skill]]
 +
 +
== AI Skill ==
 +
The AI is characterized by a set of [[Arma 3 AI Skill#Sub-Skills|sub-skills]]. The [[skillFinal|final AI skill]] is unfluenced by [[Arma 3 AI Skill#Changing AI Skill|several factors]]. Additionally each sub-skill is then interpolated with the values set in CfgAISkill.
 +
 +
== Changing AI Skill ==
 +
=== Players ===
 
[[File:A3_AISkill_Options.jpg|thumb|Difficulty Menu]]
 
[[File:A3_AISkill_Options.jpg|thumb|Difficulty Menu]]
 +
* As player one can only influence AI skill by changing the global skill settings '''Skill''' and '''Precision'''. One has also the option to choose one of the default '''AI Levels'''.
 +
**Skill: Influences multiple sub-skills related to the AIs "intelligence". If the value is set too low, the AI will be dumb.
 +
**Precision: Influences sub-skilles related to AIs precision. If the value is set too high, the AI will have a super human precision. Lower values result mostly in interesting fire fights.
 +
{{Feature|Informative|Changing the AI difficulty settings during a scenario will have no effect until the scenario is restarted.}}
 +
 +
=== Scenario Designers ===
 
[[File:A3_AISkill_EdenEditor.jpg|thumb|Skill setting in [[Eden Editor]]]]
 
[[File:A3_AISkill_EdenEditor.jpg|thumb|Skill setting in [[Eden Editor]]]]
==Overview==
+
*A scenario designer has four ways to influence the AI skill.
This page contains all information about Arma 3`s artificial intelligence, short AI.
+
**By changing the skill slider in [[Eden Editor: Object#Attributes|Eden Editor]] for each individual unit.
 +
**By using functions like [[BIS_fnc_EXP_camp_setSkill]] or [[BIS_fnc_EXP_camp_dynamicAISkill]] to set the skill of multiple AI entities at once.
 +
**By using commands like [[setSkill]].
 +
**By using the '''Set Skill''' module which allows to change the skill of AI entities for example when a trigger was activated.
  
==AI Skill==
+
=== Modders ===
 +
* A modder can influence the AI skill by overwriting [[Arma 3 AI Skill#CfgAISkill|CfgAISkill]].
  
The AI is characterized by a set of [[AI Sub-skills|sub-skills]]. Each sub-skill is influence by one of the following:
+
=== Server Admins ===
* Inherited from the value set via [[setSkill]]
+
* Server admins can change the AI skill by changing the '''aiLevelPreset''' config parameter found in server config. See [[server.armaprofile#Arma_3|Arma 3 Server Profile]] for more information.
**{{Inline code|_unit [[setSkill]] 0.8;}}
 
* Skill set in [[Eden Editor]]
 
* Exact value set by the [[setSkill]] command
 
**{{Inline code|_unit [[setSkill]] ["reloadSpeed", 0.8];}}
 
  
Each sub-skill is then interpolated with the values set in CfgAISkill.  
+
== Sub-Skills ==
 +
Sub-skills are a set of parameters ultimately defining the individual AI unit performance in the game.
  
Addionally the AI skill is also influenced by the global setting in the difficulty menu.
+
{| class="wikitable sortable"
 
+
|-
==Sub-Skills==
+
! Sub-Skill !! Effect !! Influence
Sub-skills are a set of parameters ultimately defining the individual AI unit performance in the game.
+
|-
===aimingAccuracy===
+
| aimingAccuracy ||
 
* Affects how well the AI can lead a target  
 
* Affects how well the AI can lead a target  
 
* Affects how accurately the AI estimate range and calculates bullet drop
 
* Affects how accurately the AI estimate range and calculates bullet drop
 
* Affects how well the AI compensates for weapon dispersion
 
* Affects how well the AI compensates for weapon dispersion
* Affects how much the AI will know to compensate for recoil (Higher value = more controlled fire)
+
* Affects how much the AI will know to compensate for recoil
* Affects how certain the AI must be about its aim on target before opening fire
+
* Affects how certain the AI must be about its aim on target before opening fire  
 +
||
 +
* Higher value means the AI can lead a target better
 +
* Higher value means the Ai can estimate range and calculate bullet drop more precicely
 +
* Higher value means the AI can compensate weapon dispersion better
 +
* Higher value means the AI can control the recoil better
 +
* Higher value means the AI needs to now less to open up fire
 +
|-
 +
| aimingSpeed
 +
||
 +
* Affects how quickly the AI can rotate and stabilize its aim
 +
||
 +
* Higher value means the AI can rotate and stabilize its aim faster
 +
|-
 +
| commanding
 +
||
 +
* Affects how quickly recognized targets are shared with the group
 +
||
 +
* Higher value means the AI can report targets faster
 +
|-
 +
| courage
 +
||
 +
* Affects unit's subordinates' morale
 +
||
 +
* Higher value means the AI has got more courage
 +
|-
 +
| endurance
 +
||
 +
*''Disabled in Arma3''
 +
||
 +
* ''Disabled''
 +
|-
 +
| general
 +
||
 +
* Raw "Skill", value is distributed to sub-skills unless defined otherwise. Affects the AI's decision making.
 +
||
 +
* ?
 +
|-
 +
| reloadSpeed
 +
||
 +
* Affects the delay between switching or reloading a weapon
 +
||
 +
* Higher value means the AI can switch or reload weapons faster
 +
|-
 +
| spotDistance
 +
||
 +
* Affects the AI ability to spot targets within it is visual or audible range
 +
* Affects the accuracy of the information
 +
||
 +
* Higher value means the AI is better at spotting targets
 +
* Higher value means the AI will collect information about targets more precisely
 +
|-
 +
| spotTime
 +
||
 +
* Affects how quick the AI react to death, damage or observing an enemy
 +
||
 +
* Higher value means the AI will react faster to death, damage or enemies
 +
|-
 +
| aimingShake
 +
||
 +
* Affects how steadily the AI can hold a weapon
 +
||
 +
* Higher value means the AI will be more precise
 +
|}
  
===aimingShake===
+
== CfgAISkill ==
* Affects how steadily the AI can hold a weapon (Higher value = less weapon sway)
+
CfgAISkill is a set of arrays, related to [[Arma 3 AI Skill#Sub-Skills|Sub-Skills]], defining the interpolation curve of each of the sub-skill. They can be changed by a mod for example.
 
+
=== Example ===
===aimingSpeed===
+
[[File:CfgAISkill.jpg|thumb|Interpolation with vanilla A3 CfgAISkill]]
* Affects how quickly the AI can rotate and stabilize its aim (Higher value = faster, less error)
+
In {w, x, y, z} value from (w,y) gets interpolated into (x,z)
 
 
===commanding===
 
* Affects how quickly recognized targets are shared with the group (Higher value = faster reporting)
 
  
===courage===
+
*''spotDistance[] = {'''0''', <span style="color: purple;">0.2</span>, '''1''', <span style="color: purple;">0.4</span>};''
* Affects unit's subordinates' morale (Higher value = more courage)
+
**Value in a range '''0-1''' will change into value in a range <span style="color: purple;">0.2-0.4</span>.
 +
*''setSkill ["spotDistance", 0.5]''
 +
**Results in ''skill "spotDistance"'' returning ''0.3''
  
===endurance===
+
{{Feature|Informative|More than 2 pairs of defining values can be used (minimum is 2 pairs). The values are used to interpolate on run-time, so even after setting sub-skill by script command it will be interpolated and bound by this array.}}
*''Disabled in Arma3''
 
  
===general===
+
=== Defaults for Arma 3 ===
* Raw "Skill", value is distributed to sub-skills unless defined otherwise. Affects the AI's decision making.
+
==== Table ====
 +
{| class="wikitable"
 +
|-
 +
! Sub-Skill !! minInputSkillLimit (w) !! resultingSubSkillLowerBoundary (x) !! maxInputSkillLimit (y) !! resultingSubSkillLowerBoundary (z)
 +
|-
 +
| aimingAccuracy || 0 || 0 || 1 || 1
 +
|-
 +
| aimingShake || 0 || 0 || 1 || 1
 +
|-
 +
| aimingSpeed || 0 || 0.5 || 1 || 1
 +
|-
 +
| commanding|| 0 || 0 || 1 || 1
 +
|-
 +
| courage || 0 || 0 || 1 || 1
 +
|-
 +
| endurance || 0 || 0 || 1 || 1
 +
|-
 +
| general || 0 || 0 || 1 || 1
 +
|-
 +
| reloadSpeed || 0 || 0 || 1 || 1
 +
|-
 +
| spotDistance || 0 || 0 || 1 || 1
 +
|-
 +
| spotTime || 0 || 0 || 1 || 1
 +
|}
  
===reloadSpeed===
+
==== Config ====
* Affects the delay between switching or reloading a weapon (Higher value = less delay)
+
<spoiler>
 
 
===spotDistance===
 
* Affects the AI ability to spot targets within it's visual or audible range (Higher value = more likely to spot)
 
* Affects the accuracy of the information (Higher value = more accurate information)
 
 
 
===spotTime===
 
* Affects how quick the AI react to death, damage or observing an enemy (Higher value = quicker reaction)
 
 
 
==CfgAISkill==
 
CfgAISkill is a set of arrays, related to [[AI Sub-skills]], defining the interpolation curve of each of the sub-skill.
 
===Example===
 
[[File:CfgAISkill.jpg|thumb|Interpolation with vanilla A3 CfgAISkill]]
 
In {w, x, y, z} value from (w,y) gets interpolated into (x,z)
 
''spotDistance[] = {0,0.2, 1,0.4};'' value in a range 0-1 will change into value in a range 0.2-0.4.
 
''setSkill ["spotDistance", 0.5]'' results in ''skill "spotDistance"'' returning ''0.3''
 
===Notes===
 
More than 2 pairs of defining values can be used (minimum is 2 pairs).
 
 
 
The values are used to interpolate on run-time, so even after setting sub-skill by script command it will be interpolated and bound by this array.
 
 
 
===Defaults for Arma 3===
 
 
  aimingAccuracy[] = {0, 0, 1, 1};
 
  aimingAccuracy[] = {0, 0, 1, 1};
 
  aimingShake[] = {0, 0, 1, 1};
 
  aimingShake[] = {0, 0, 1, 1};
Line 76: Line 153:
 
  commanding[] = {0, 0, 1, 1};
 
  commanding[] = {0, 0, 1, 1};
 
  courage[] = {0, 0, 1, 1};
 
  courage[] = {0, 0, 1, 1};
  endurance[] = {0, 0, 1, 1};
+
  endurance[] = {0, 0, 1, 1}; '''Has been disabled in {{arma3}}'''
 
  general[] = {0, 0, 1, 1};
 
  general[] = {0, 0, 1, 1};
 
  reloadSpeed[] = {0, 0, 1, 1};
 
  reloadSpeed[] = {0, 0, 1, 1};
 
  spotDistance[] = {0, 0, 1, 1};
 
  spotDistance[] = {0, 0, 1, 1};
 
  spotTime[] = {0, 0, 1, 1};
 
  spotTime[] = {0, 0, 1, 1};
 +
</spoiler>
  
 
== Related Commands ==
 
== Related Commands ==
Line 86: Line 164:
 
*[[setSkill]]
 
*[[setSkill]]
 
*[[skillFinal]]
 
*[[skillFinal]]
 +
*[[allowFleeing]]
 +
 +
== External Links ==
 +
*{{ExternalLink|link= https://forums.bohemia.net/forums/topic/219929-the-mystical-skillfinal-formula-reverse-engineering-it/|text= BIS Forums AI Skill}}
 +
*{{ExternalLink|link= https://forums.bohemia.net/forums/topic/223493-ai-facts-myths-compilation-list/|text= AI Facts & Myths Compilation List}}

Latest revision as of 15:25, 26 July 2021

Some information on this page were not confirmed by BIS!
AI skill/level/final skill

AI Skill

The AI is characterized by a set of sub-skills. The final AI skill is unfluenced by several factors. Additionally each sub-skill is then interpolated with the values set in CfgAISkill.

Changing AI Skill

Players

Difficulty Menu
  • As player one can only influence AI skill by changing the global skill settings Skill and Precision. One has also the option to choose one of the default AI Levels.
    • Skill: Influences multiple sub-skills related to the AIs "intelligence". If the value is set too low, the AI will be dumb.
    • Precision: Influences sub-skilles related to AIs precision. If the value is set too high, the AI will have a super human precision. Lower values result mostly in interesting fire fights.
Changing the AI difficulty settings during a scenario will have no effect until the scenario is restarted.

Scenario Designers

Skill setting in Eden Editor
  • A scenario designer has four ways to influence the AI skill.

Modders

  • A modder can influence the AI skill by overwriting CfgAISkill.

Server Admins

  • Server admins can change the AI skill by changing the aiLevelPreset config parameter found in server config. See Arma 3 Server Profile for more information.

Sub-Skills

Sub-skills are a set of parameters ultimately defining the individual AI unit performance in the game.

Sub-Skill Effect Influence
aimingAccuracy
  • Affects how well the AI can lead a target
  • Affects how accurately the AI estimate range and calculates bullet drop
  • Affects how well the AI compensates for weapon dispersion
  • Affects how much the AI will know to compensate for recoil
  • Affects how certain the AI must be about its aim on target before opening fire
  • Higher value means the AI can lead a target better
  • Higher value means the Ai can estimate range and calculate bullet drop more precicely
  • Higher value means the AI can compensate weapon dispersion better
  • Higher value means the AI can control the recoil better
  • Higher value means the AI needs to now less to open up fire
aimingSpeed
  • Affects how quickly the AI can rotate and stabilize its aim
  • Higher value means the AI can rotate and stabilize its aim faster
commanding
  • Affects how quickly recognized targets are shared with the group
  • Higher value means the AI can report targets faster
courage
  • Affects unit's subordinates' morale
  • Higher value means the AI has got more courage
endurance
  • Disabled in Arma3
  • Disabled
general
  • Raw "Skill", value is distributed to sub-skills unless defined otherwise. Affects the AI's decision making.
  •  ?
reloadSpeed
  • Affects the delay between switching or reloading a weapon
  • Higher value means the AI can switch or reload weapons faster
spotDistance
  • Affects the AI ability to spot targets within it is visual or audible range
  • Affects the accuracy of the information
  • Higher value means the AI is better at spotting targets
  • Higher value means the AI will collect information about targets more precisely
spotTime
  • Affects how quick the AI react to death, damage or observing an enemy
  • Higher value means the AI will react faster to death, damage or enemies
aimingShake
  • Affects how steadily the AI can hold a weapon
  • Higher value means the AI will be more precise

CfgAISkill

CfgAISkill is a set of arrays, related to Sub-Skills, defining the interpolation curve of each of the sub-skill. They can be changed by a mod for example.

Example

Interpolation with vanilla A3 CfgAISkill

In {w, x, y, z} value from (w,y) gets interpolated into (x,z)

  • spotDistance[] = {0, 0.2, 1, 0.4};
    • Value in a range 0-1 will change into value in a range 0.2-0.4.
  • setSkill ["spotDistance", 0.5]
    • Results in skill "spotDistance" returning 0.3
More than 2 pairs of defining values can be used (minimum is 2 pairs). The values are used to interpolate on run-time, so even after setting sub-skill by script command it will be interpolated and bound by this array.

Defaults for Arma 3

Table

Sub-Skill minInputSkillLimit (w) resultingSubSkillLowerBoundary (x) maxInputSkillLimit (y) resultingSubSkillLowerBoundary (z)
aimingAccuracy 0 0 1 1
aimingShake 0 0 1 1
aimingSpeed 0 0.5 1 1
commanding 0 0 1 1
courage 0 0 1 1
endurance 0 0 1 1
general 0 0 1 1
reloadSpeed 0 0 1 1
spotDistance 0 0 1 1
spotTime 0 0 1 1

Config

Show text


Related Commands

External Links