From e390cf8ab08be115c3581dd2bdcc5697d51f0476 Mon Sep 17 00:00:00 2001 From: Bob Date: Tue, 21 Sep 2010 00:57:31 +1200 Subject: [PATCH] fix real-ra map importer when map isn't in game root --- OpenRA.Editor/Form1.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/OpenRA.Editor/Form1.cs b/OpenRA.Editor/Form1.cs index 907805d301..ddb7f10677 100644 --- a/OpenRA.Editor/Form1.cs +++ b/OpenRA.Editor/Form1.cs @@ -349,9 +349,11 @@ namespace OpenRA.Editor void ImportLegacyMapClicked(object sender, EventArgs e) { + var currentDirectory = Directory.GetCurrentDirectory(); using (var ofd = new OpenFileDialog { Filter = "Legacy maps (*.ini;*.mpr)|*.ini;*.mpr" }) if (DialogResult.OK == ofd.ShowDialog()) { + Directory.SetCurrentDirectory( currentDirectory ); /* massive hack: we should be able to call NewMap() with the imported Map object, * but something's not right internally in it, unless loaded via the real maploader */