diff --git a/X2WOTCCommunityHighlander/Config/XComGame.ini b/X2WOTCCommunityHighlander/Config/XComGame.ini index e11646fce..e7d47ca8e 100644 --- a/X2WOTCCommunityHighlander/Config/XComGame.ini +++ b/X2WOTCCommunityHighlander/Config/XComGame.ini @@ -282,3 +282,8 @@ iMixedCharacterPoolChance = 50 ; Uncomment the following line to make the Unit Flag damage preview show minimum damage ; rather than maximum damage. ; bUseMinDamageForUnitFlagPreview = true + +;;; HL-Docs: ref:DisableAimAssist +; Uncomment the following line to disable Aim Assist. +; bDisableAimAssist = true + diff --git a/X2WOTCCommunityHighlander/Src/XComGame/Classes/CHHelpers.uc b/X2WOTCCommunityHighlander/Src/XComGame/Classes/CHHelpers.uc index 582784e63..fe7e2d7bd 100644 --- a/X2WOTCCommunityHighlander/Src/XComGame/Classes/CHHelpers.uc +++ b/X2WOTCCommunityHighlander/Src/XComGame/Classes/CHHelpers.uc @@ -254,6 +254,10 @@ var config int iMixedCharacterPoolChance; // Variable for Issue #579 - makes UIUnitFlagManager use ability's minimum damage rather than maximum damage for the preview. var config bool bUseMinDamageForUnitFlagPreview; +// Variable for Issue #1228 - disables Aim Assist. +var config bool bDisableAimAssist; + + // Start Issue #885 enum EHLDelegateReturn { diff --git a/X2WOTCCommunityHighlander/Src/XComGame/Classes/X2AbilityToHitCalc_StandardAim.uc b/X2WOTCCommunityHighlander/Src/XComGame/Classes/X2AbilityToHitCalc_StandardAim.uc index 89b2bc236..528c72564 100644 --- a/X2WOTCCommunityHighlander/Src/XComGame/Classes/X2AbilityToHitCalc_StandardAim.uc +++ b/X2WOTCCommunityHighlander/Src/XComGame/Classes/X2AbilityToHitCalc_StandardAim.uc @@ -823,6 +823,15 @@ function int GetModifiedHitChanceForCurrentDifficulty(XComGameState_Player Insti local XComGameState_Unit Unit; local ETeam TargetTeam; + // Start Issue #1228 + /// HL-Docs: feature:DisableAimAssist; issue:1228; tags:tactical + /// This feature adds a config variable that acts as a master switch for disabling all instances of Aim Assist. + if (class'CHHelpers'.default.bDisableAimAssist) + { + return BaseHitChance; + } + // End Issue #1228 + ModifiedHitChance = BaseHitChance; History = `XCOMHISTORY;