diff --git a/scripts/Windows/Software/TrackMania Nations Forever/Manage.ps1 b/scripts/Windows/Software/TrackMania Nations Forever/Manage.ps1 index e2bddc0b..9e1fd28e 100644 --- a/scripts/Windows/Software/TrackMania Nations Forever/Manage.ps1 +++ b/scripts/Windows/Software/TrackMania Nations Forever/Manage.ps1 @@ -10,7 +10,7 @@ Start-SoftwareInstaller @PSBoundParameters ` foreach ($feature in @("DirectPlay", "NetFx3")) { if ((Get-WindowsOptionalFeature -Online -FeatureName $feature).State -ne "Enabled") { Write-Information "Enabling the ``$feature`` featureā€¦"; - $null = Enable-WindowsOptionalFeature -Online -All -FeatureName $feature; + choco install --source windowsFeatures -y $feature; } Install-WingetPackage Nadeo.TrackManiaNationsForever; diff --git a/scripts/Windows/Software/TrackMania United Forever/Manage.ps1 b/scripts/Windows/Software/TrackMania United Forever/Manage.ps1 index da083bbe..b15ea704 100644 --- a/scripts/Windows/Software/TrackMania United Forever/Manage.ps1 +++ b/scripts/Windows/Software/TrackMania United Forever/Manage.ps1 @@ -14,7 +14,7 @@ Start-SoftwareInstaller @PSBoundParameters ` foreach ($feature in @("DirectPlay", "NetFx3")) { if ((Get-WindowsOptionalFeature -Online -FeatureName $feature).State -ne "Enabled") { Write-Information "Enabling the ``$feature`` featureā€¦"; - $null = Enable-WindowsOptionalFeature -Online -All -FeatureName $feature; + choco install --source windowsFeatures -y $feature; } }