diff --git a/OpenRA.Game/OpenRA.Game.csproj b/OpenRA.Game/OpenRA.Game.csproj
index 19dacce410..a54198d055 100644
--- a/OpenRA.Game/OpenRA.Game.csproj
+++ b/OpenRA.Game/OpenRA.Game.csproj
@@ -107,11 +107,8 @@
-
-
-
@@ -263,10 +260,7 @@
-
-
-
@@ -275,11 +269,6 @@
-
-
-
-
-
@@ -303,7 +292,6 @@
-
diff --git a/OpenRA.Game/FileFormats/Blowfish.cs b/OpenRA.Mods.Cnc/FileFormats/Blowfish.cs
similarity index 99%
rename from OpenRA.Game/FileFormats/Blowfish.cs
rename to OpenRA.Mods.Cnc/FileFormats/Blowfish.cs
index 66f274cec0..9607fe66c2 100644
--- a/OpenRA.Game/FileFormats/Blowfish.cs
+++ b/OpenRA.Mods.Cnc/FileFormats/Blowfish.cs
@@ -9,7 +9,7 @@
*/
#endregion
-namespace OpenRA.FileFormats
+namespace OpenRA.Mods.Cnc.FileFormats
{
class Blowfish
{
diff --git a/OpenRA.Game/FileFormats/BlowfishKeyProvider.cs b/OpenRA.Mods.Cnc/FileFormats/BlowfishKeyProvider.cs
similarity index 99%
rename from OpenRA.Game/FileFormats/BlowfishKeyProvider.cs
rename to OpenRA.Mods.Cnc/FileFormats/BlowfishKeyProvider.cs
index 9ba511baf8..1806b11a19 100644
--- a/OpenRA.Game/FileFormats/BlowfishKeyProvider.cs
+++ b/OpenRA.Mods.Cnc/FileFormats/BlowfishKeyProvider.cs
@@ -12,7 +12,7 @@
using System;
using System.Linq;
-namespace OpenRA.FileFormats
+namespace OpenRA.Mods.Cnc.FileFormats
{
/* TODO: Convert this direct C port into readable code. */
diff --git a/OpenRA.Game/FileFormats/CRC32.cs b/OpenRA.Mods.Cnc/FileFormats/CRC32.cs
similarity index 99%
rename from OpenRA.Game/FileFormats/CRC32.cs
rename to OpenRA.Mods.Cnc/FileFormats/CRC32.cs
index 3faa84f7b5..f4e954e2ba 100644
--- a/OpenRA.Game/FileFormats/CRC32.cs
+++ b/OpenRA.Mods.Cnc/FileFormats/CRC32.cs
@@ -9,7 +9,7 @@
*/
#endregion
-namespace OpenRA.FileFormats
+namespace OpenRA.Mods.Cnc.FileFormats
{
///
/// Static class that uses a lookup table to calculates CRC32
diff --git a/OpenRA.Game/FileSystem/IdxEntry.cs b/OpenRA.Mods.Cnc/FileFormats/IdxEntry.cs
similarity index 94%
rename from OpenRA.Game/FileSystem/IdxEntry.cs
rename to OpenRA.Mods.Cnc/FileFormats/IdxEntry.cs
index bd16a402e4..0b303d6095 100644
--- a/OpenRA.Game/FileSystem/IdxEntry.cs
+++ b/OpenRA.Mods.Cnc/FileFormats/IdxEntry.cs
@@ -9,10 +9,9 @@
*/
#endregion
-using System.Collections.Generic;
using System.IO;
-namespace OpenRA.FileSystem
+namespace OpenRA.Mods.Cnc.FileFormats
{
public class IdxEntry
{
diff --git a/OpenRA.Game/FileFormats/IdxReader.cs b/OpenRA.Mods.Cnc/FileFormats/IdxReader.cs
similarity index 95%
rename from OpenRA.Game/FileFormats/IdxReader.cs
rename to OpenRA.Mods.Cnc/FileFormats/IdxReader.cs
index 05c2c89acf..11349fb793 100644
--- a/OpenRA.Game/FileFormats/IdxReader.cs
+++ b/OpenRA.Mods.Cnc/FileFormats/IdxReader.cs
@@ -11,9 +11,8 @@
using System.Collections.Generic;
using System.IO;
-using OpenRA.FileSystem;
-namespace OpenRA.FileFormats
+namespace OpenRA.Mods.Cnc.FileFormats
{
public class IdxReader
{
diff --git a/OpenRA.Game/FileFormats/XccGlobalDatabase.cs b/OpenRA.Mods.Cnc/FileFormats/XccGlobalDatabase.cs
similarity index 96%
rename from OpenRA.Game/FileFormats/XccGlobalDatabase.cs
rename to OpenRA.Mods.Cnc/FileFormats/XccGlobalDatabase.cs
index 6028f29ae8..0fc6442b2a 100644
--- a/OpenRA.Game/FileFormats/XccGlobalDatabase.cs
+++ b/OpenRA.Mods.Cnc/FileFormats/XccGlobalDatabase.cs
@@ -13,7 +13,7 @@ using System;
using System.Collections.Generic;
using System.IO;
-namespace OpenRA.FileFormats
+namespace OpenRA.Mods.Cnc.FileFormats
{
public class XccGlobalDatabase : IDisposable
{
diff --git a/OpenRA.Game/FileFormats/XccLocalDatabase.cs b/OpenRA.Mods.Cnc/FileFormats/XccLocalDatabase.cs
similarity index 97%
rename from OpenRA.Game/FileFormats/XccLocalDatabase.cs
rename to OpenRA.Mods.Cnc/FileFormats/XccLocalDatabase.cs
index 802e2b349a..1459c5e5b8 100644
--- a/OpenRA.Game/FileFormats/XccLocalDatabase.cs
+++ b/OpenRA.Mods.Cnc/FileFormats/XccLocalDatabase.cs
@@ -14,7 +14,7 @@ using System.IO;
using System.Linq;
using System.Text;
-namespace OpenRA.FileFormats
+namespace OpenRA.Mods.Cnc.FileFormats
{
public class XccLocalDatabase
{
diff --git a/OpenRA.Game/FileSystem/BagFile.cs b/OpenRA.Mods.Cnc/FileSystem/BagFile.cs
similarity index 95%
rename from OpenRA.Game/FileSystem/BagFile.cs
rename to OpenRA.Mods.Cnc/FileSystem/BagFile.cs
index 0f6e9dfe94..63199bf12c 100644
--- a/OpenRA.Game/FileSystem/BagFile.cs
+++ b/OpenRA.Mods.Cnc/FileSystem/BagFile.cs
@@ -13,10 +13,12 @@ using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
-using OpenRA.FileFormats;
+using OpenRA.FileSystem;
+using OpenRA.Mods.Cnc.FileFormats;
using OpenRA.Primitives;
+using FS = OpenRA.FileSystem.FileSystem;
-namespace OpenRA.FileSystem
+namespace OpenRA.Mods.Cnc.FileSystem
{
public class AudioBagLoader : IPackageLoader
{
@@ -109,7 +111,7 @@ namespace OpenRA.FileSystem
return index.ContainsKey(filename);
}
- public IReadOnlyPackage OpenPackage(string filename, FileSystem context)
+ public IReadOnlyPackage OpenPackage(string filename, FS context)
{
// Not implemented
return null;
@@ -121,7 +123,7 @@ namespace OpenRA.FileSystem
}
}
- bool IPackageLoader.TryParsePackage(Stream s, string filename, FileSystem context, out IReadOnlyPackage package)
+ bool IPackageLoader.TryParsePackage(Stream s, string filename, FS context, out IReadOnlyPackage package)
{
if (!filename.EndsWith(".bag", StringComparison.InvariantCultureIgnoreCase))
{
diff --git a/OpenRA.Game/FileSystem/BigFile.cs b/OpenRA.Mods.Cnc/FileSystem/BigFile.cs
similarity index 92%
rename from OpenRA.Game/FileSystem/BigFile.cs
rename to OpenRA.Mods.Cnc/FileSystem/BigFile.cs
index f5e6ac7016..cd6883e439 100644
--- a/OpenRA.Game/FileSystem/BigFile.cs
+++ b/OpenRA.Mods.Cnc/FileSystem/BigFile.cs
@@ -12,8 +12,10 @@
using System;
using System.Collections.Generic;
using System.IO;
+using OpenRA.FileSystem;
+using FS = OpenRA.FileSystem.FileSystem;
-namespace OpenRA.FileSystem
+namespace OpenRA.Mods.Cnc.FileSystem
{
public class BigLoader : IPackageLoader
{
@@ -97,7 +99,7 @@ namespace OpenRA.FileSystem
return index.ContainsKey(filename);
}
- public IReadOnlyPackage OpenPackage(string filename, FileSystem context)
+ public IReadOnlyPackage OpenPackage(string filename, FS context)
{
// Not implemented
return null;
@@ -109,7 +111,7 @@ namespace OpenRA.FileSystem
}
}
- bool IPackageLoader.TryParsePackage(Stream s, string filename, FileSystem context, out IReadOnlyPackage package)
+ bool IPackageLoader.TryParsePackage(Stream s, string filename, FS context, out IReadOnlyPackage package)
{
// Take a peek at the file signature
var signature = s.ReadASCII(4);
diff --git a/OpenRA.Game/FileSystem/MixFile.cs b/OpenRA.Mods.Cnc/FileSystem/MixFile.cs
similarity index 96%
rename from OpenRA.Game/FileSystem/MixFile.cs
rename to OpenRA.Mods.Cnc/FileSystem/MixFile.cs
index 7585b6f9ec..d8ed30bd3f 100644
--- a/OpenRA.Game/FileSystem/MixFile.cs
+++ b/OpenRA.Mods.Cnc/FileSystem/MixFile.cs
@@ -14,9 +14,12 @@ using System.Collections.Generic;
using System.IO;
using System.Linq;
using OpenRA.FileFormats;
+using OpenRA.FileSystem;
+using OpenRA.Mods.Cnc.FileFormats;
using OpenRA.Primitives;
+using FS = OpenRA.FileSystem.FileSystem;
-namespace OpenRA.FileSystem
+namespace OpenRA.Mods.Cnc.FileSystem
{
public class MixLoader : IPackageLoader
{
@@ -222,7 +225,7 @@ namespace OpenRA.FileSystem
return index.ContainsKey(filename);
}
- public IReadOnlyPackage OpenPackage(string filename, FileSystem context)
+ public IReadOnlyPackage OpenPackage(string filename, FS context)
{
IReadOnlyPackage package;
var childStream = GetStream(filename);
@@ -242,7 +245,7 @@ namespace OpenRA.FileSystem
}
}
- bool IPackageLoader.TryParsePackage(Stream s, string filename, FileSystem context, out IReadOnlyPackage package)
+ bool IPackageLoader.TryParsePackage(Stream s, string filename, FS context, out IReadOnlyPackage package)
{
if (!filename.EndsWith(".mix", StringComparison.InvariantCultureIgnoreCase))
{
diff --git a/OpenRA.Game/FileSystem/PackageEntry.cs b/OpenRA.Mods.Cnc/FileSystem/PackageEntry.cs
similarity index 97%
rename from OpenRA.Game/FileSystem/PackageEntry.cs
rename to OpenRA.Mods.Cnc/FileSystem/PackageEntry.cs
index 27cb7e3ac7..b24240e137 100644
--- a/OpenRA.Game/FileSystem/PackageEntry.cs
+++ b/OpenRA.Mods.Cnc/FileSystem/PackageEntry.cs
@@ -13,9 +13,9 @@ using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
-using OpenRA.FileFormats;
+using OpenRA.Mods.Cnc.FileFormats;
-namespace OpenRA.FileSystem
+namespace OpenRA.Mods.Cnc.FileSystem
{
public enum PackageHashType { Classic, CRC32 }
diff --git a/OpenRA.Game/FileSystem/Pak.cs b/OpenRA.Mods.Cnc/FileSystem/Pak.cs
similarity index 91%
rename from OpenRA.Game/FileSystem/Pak.cs
rename to OpenRA.Mods.Cnc/FileSystem/Pak.cs
index 76692c61ac..65ce6eb777 100644
--- a/OpenRA.Game/FileSystem/Pak.cs
+++ b/OpenRA.Mods.Cnc/FileSystem/Pak.cs
@@ -12,8 +12,10 @@
using System;
using System.Collections.Generic;
using System.IO;
+using OpenRA.FileSystem;
+using FS = OpenRA.FileSystem.FileSystem;
-namespace OpenRA.FileSystem
+namespace OpenRA.Mods.Cnc.FileSystem
{
public class PakFileLoader : IPackageLoader
{
@@ -77,7 +79,7 @@ namespace OpenRA.FileSystem
return index.ContainsKey(filename);
}
- public IReadOnlyPackage OpenPackage(string filename, FileSystem context)
+ public IReadOnlyPackage OpenPackage(string filename, FS context)
{
// Not implemented
return null;
@@ -89,7 +91,7 @@ namespace OpenRA.FileSystem
}
}
- bool IPackageLoader.TryParsePackage(Stream s, string filename, FileSystem context, out IReadOnlyPackage package)
+ bool IPackageLoader.TryParsePackage(Stream s, string filename, FS context, out IReadOnlyPackage package)
{
if (!filename.EndsWith(".pak", StringComparison.InvariantCultureIgnoreCase))
{
diff --git a/OpenRA.Mods.Cnc/OpenRA.Mods.Cnc.csproj b/OpenRA.Mods.Cnc/OpenRA.Mods.Cnc.csproj
index b648538d9d..fa3b968095 100644
--- a/OpenRA.Mods.Cnc/OpenRA.Mods.Cnc.csproj
+++ b/OpenRA.Mods.Cnc/OpenRA.Mods.Cnc.csproj
@@ -134,6 +134,19 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/OpenRA.Mods.Common/UtilityCommands/ListMixContentsCommand.cs b/OpenRA.Mods.Cnc/UtilityCommands/ListMixContentsCommand.cs
similarity index 92%
rename from OpenRA.Mods.Common/UtilityCommands/ListMixContentsCommand.cs
rename to OpenRA.Mods.Cnc/UtilityCommands/ListMixContentsCommand.cs
index 2821ee5c4b..875664e1e7 100644
--- a/OpenRA.Mods.Common/UtilityCommands/ListMixContentsCommand.cs
+++ b/OpenRA.Mods.Cnc/UtilityCommands/ListMixContentsCommand.cs
@@ -13,10 +13,10 @@ using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
-using OpenRA.FileFormats;
-using OpenRA.FileSystem;
+using OpenRA.Mods.Cnc.FileFormats;
+using OpenRA.Mods.Cnc.FileSystem;
-namespace OpenRA.Mods.Common.UtilityCommands
+namespace OpenRA.Mods.Cnc.UtilityCommands
{
class ListMixContents : IUtilityCommand
{
diff --git a/OpenRA.Mods.Common/OpenRA.Mods.Common.csproj b/OpenRA.Mods.Common/OpenRA.Mods.Common.csproj
index cdc9bc4c18..39d0d7652a 100644
--- a/OpenRA.Mods.Common/OpenRA.Mods.Common.csproj
+++ b/OpenRA.Mods.Common/OpenRA.Mods.Common.csproj
@@ -760,7 +760,6 @@
-