Heroes of Might and Magic III: The Restoration of Erathia

From LANCommander
Developers
Loki SoftwareNew World Computing
Publishers
The 3DO CompanyLoki Software
Release Date
Windows: February 28, 1999
Genres
Turn-based strategy (TBS)StrategyRole-playing (RPG)
View at PCGamingWiki

Actions

Name Path Arguments Working Directory Primary
Play {InstallDir}\Heroes3 HD.exe True

Install Script

$Display = Get-PrimaryDisplay
$configpath = "$InstallDirectory\_HD3_Data\Settings\sod.ini"

# Use regex to replace text within a file. Quotes are escaped by double quoting ("")
Write-ReplaceContentInFile -Pattern '^\<Graphics.Resolution\> = (.+)' -Substitution "<Graphics.Resolution> = $($Display.Bounds.Width)x$($Display.Bounds.Height)" -FilePath "$configPath"

Name Change Script

$configpath = "$InstallDirectory\_HD3_Data\Settings\sod.ini"

# Use regex to replace text within a file. Quotes are escaped by double quoting ("")
Write-ReplaceContentInFile -Pattern '^<Network Default Name> = (.+)' -Substitution "<Network Default Name> = ""$NewPlayerAlias""" -FilePath "$configPath"