changeset 106:41e82ba675dc

Re #324: Add saving of Race and System data to files * Swap to new method call for saving army * Temporarily cause NullRef exceptions by removing the setting of a saver
author IBBoard <dev@ibboard.co.uk>
date Mon, 28 Feb 2011 21:10:18 +0000
parents 0ddef7087602
children f7e02b1d96e1
files FrmMainWindow.cs
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line diff
     1.1 --- a/FrmMainWindow.cs	Mon Feb 28 20:23:22 2011 +0000
     1.2 +++ b/FrmMainWindow.cs	Mon Feb 28 21:10:18 2011 +0000
     1.3 @@ -158,7 +158,8 @@
     1.4  			WarFoundryLoader.GetDefault().AddLoadDirectory(new DirectoryInfo(Constants.ExecutablePath + Constants.DirectoryString + "data"));
     1.5  			WarFoundryLoader.GetDefault().RegisterFactory(WarFoundryXmlFactory.GetFactory());
     1.6  			WarFoundryLoader.GetDefault().FileLoadingFinished += FileLoadingFinished;
     1.7 -			WarFoundrySaver.SetFileSaver(new WarFoundryXmlSaver());
     1.8 +			//TODO: Replace with a new saver using the "lots of files in one" interface
     1.9 +			//WarFoundrySaver.SetFileSaver(new WarFoundryXmlArmySaver());
    1.10  
    1.11  			logger.Debug("Initialising complete - seeing if we can load default army or system");
    1.12  
    1.13 @@ -900,7 +901,7 @@
    1.14  
    1.15  				try
    1.16  				{
    1.17 -					saveSuccess = WarFoundrySaver.GetSaver().Save(WarFoundryCore.CurrentArmy, filePath);
    1.18 +					saveSuccess = WarFoundrySaver.GetSaver().Save(filePath, WarFoundryCore.CurrentArmy);
    1.19  				}
    1.20  				catch (Exception ex)
    1.21  				{