Descent II: Difference between revisions
DoctorDalek (talk | contribs) (Created new page for Descent II) |
DoctorDalek (talk | contribs) No edit summary |
||
Line 5: | Line 5: | ||
{{Game.InfoBox.Developer|Parallax Software}} | {{Game.InfoBox.Developer|Parallax Software}} | ||
|Publishers = | |Publishers = | ||
{{Game.InfoBox. | {{Game.InfoBox.Publisher|MacPlay}}{{Game.InfoBox.Publisher|Interplay}} | ||
|Release Date = | |Release Date = | ||
{{Game.InfoBox.ReleaseDate|Windows|March 13, 1996}} | {{Game.InfoBox.ReleaseDate|Windows|March 13, 1996}} |
Latest revision as of 00:41, 22 February 2024
Developers | |
---|---|
Parallax Software | |
Publishers | |
MacPlayInterplay | |
Release Date | |
Windows: March 13, 1996 | |
Genres | |
SimulatorShooter | |
View at PCGamingWiki |
Actions
Name | Path | Arguments | Working Directory | Primary |
---|---|---|---|---|
Play | {InstallDir}\d2x-retro-1.4.X3.exe | True |
Install Script
Sets the resolution of the game to the machine's current resolution.
# Bounds are accessible by $Display.Bounds.Width and $Display.Bounds.Height
$Display = Get-PrimaryDisplay
# Use regex to replace text within a file. Quotes are escaped by double quoting ("")
Write-ReplaceContentInFile -Pattern '^ResolutionX=(.+)' -Substitution "ResolutionX=$($Display.Bounds.Width)" -FilePath "$InstallDirectory\DESCENT.CFG"
Write-ReplaceContentInFile -Pattern '^ResolutionY=(.+)' -Substitution "ResolutionY=$($Display.Bounds.Height)" -FilePath "$InstallDirectory\DESCENT.CFG"
Name Change Script
This script will take the old player's profile and rename it to the new name. If the old profile doesn't exist, a new one will be copied from "Template.<ext>.example". Finally, the last player variable in the config will be updated to the new name. Descent and modern ports require the name to be 8 characters and lowercased, so this script will handle that as well.
# Trim a string down to a specified amount of characters
if ($NewPlayerAlias.Length -gt 8) {
$NewPlayerAlias = $NewPlayerAlias.Substring(0, 8).ToLower();
}
if ($OldPlayerAlias.Length -gt 8) {
$OldPlayerAlias = $OldPlayerAlias.Substring(0, 8).ToLower();
}
if (Test-Path "$InstallDirectory\$OldPlayerAlias.plr") {
Rename-Item -Path "$InstallDirectory\$OldPlayerAlias.plr" -NewName "$InstallDirectory\$NewPlayerAlias.plr"
}
else {
Copy-Item -Path "$InstallDirectory\Template.plr.example" -Destination "$InstallDirectory\$NewPlayerAlias.plr"
}
if (Test-Path "$InstallDirectory\$OldPlayerAlias.plx") {
Rename-Item -Path "$InstallDirectory\$OldPlayerAlias.plx" -NewName "$InstallDirectory\$NewPlayerAlias.plx"
}
else {
Copy-Item -Path "$InstallDirectory\Template.plx.example" -Destination "$InstallDirectory\$NewPlayerAlias.plx"
}
# Use regex to replace text within a file. Quotes are escaped by double quoting ("")
Write-ReplaceContentInFile -Pattern '^LastPlayer=(.+)' -Substitution "LastPlayer=$NewPlayerAlias" -FilePath "$InstallDirectory\DESCENT.CFG"