unify disk check between music install and game install for cnc

This commit is contained in:
Chris Forbes
2011-10-06 23:43:32 +13:00
parent 281f706b02
commit e9a4ec5403
2 changed files with 13 additions and 10 deletions

View File

@@ -215,11 +215,7 @@ namespace OpenRA.Mods.Cnc.Widgets.Logic
void CheckForDisk()
{
Func<string, bool> ValidDiskFilter = diskRoot => File.Exists(diskRoot+Path.DirectorySeparatorChar+"CONQUER.MIX") &&
File.Exists(diskRoot+Path.DirectorySeparatorChar+"DESERT.MIX") &&
File.Exists(new string[] { diskRoot, "INSTALL", "SETUP.Z" }.Aggregate(Path.Combine));
var path = InstallUtils.GetMountedDisk(ValidDiskFilter);
var path = InstallUtils.GetMountedDisk(CncInstallFromCDLogic.IsValidDisk);
if (path != null)
Install(path);