Skip to content

Commit

Permalink
Write OriginalFilename in non mp games
Browse files Browse the repository at this point in the history
  • Loading branch information
GrantBartlett committed Jan 3, 2025
1 parent cdc3614 commit 6e5bf90
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions DXMainClient/DXGUI/Multiplayer/GameLobby/GameLobbyBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1593,6 +1593,11 @@ private void WriteMap(PlayerHouseInfo[] houseInfos)
IniFile mpGlobalCodeIni = new IniFile(SafePath.CombineFilePath(ProgramConstants.GamePath, "INI", "Map Code", "MultiplayerGlobalCode.ini"));
MapCodeHelper.ApplyMapCode(mapIni, mpGlobalCodeIni);
}
else
{
string mapIniFileName = Path.GetFileName(mapIni.FileName);
mapIni.SetStringValue("Basic", "OriginalFilename", mapIniFileName);
}

foreach (GameLobbyCheckBox checkBox in CheckBoxes)
checkBox.ApplyMapCode(mapIni, GameMode);
Expand All @@ -1601,9 +1606,7 @@ private void WriteMap(PlayerHouseInfo[] houseInfos)
dropDown.ApplyMapCode(mapIni, GameMode);

mapIni.MoveSectionToFirst("MultiplayerDialogSettings"); // Required by YR

string mapIniFileName = Path.GetFileName(mapIni.FileName);
mapIni.SetStringValue("Basic", "OriginalFilename", mapIniFileName);

CopySupplementalMapFiles(mapIni);

ManipulateStartingLocations(mapIni, houseInfos);
Expand Down

0 comments on commit 6e5bf90

Please sign in to comment.