changed DataDirectory property value to "GameData".

This commit is contained in:
morkt 2016-09-28 00:07:27 +04:00
parent 34209251c4
commit edc677f273

View File

@ -72,16 +72,19 @@ namespace GameRes
public int CurrentSchemeVersion { get; private set; } public int CurrentSchemeVersion { get; private set; }
public string SchemeID { get { return "GARbroDB"; } } public string SchemeID { get { return "GARbroDB"; } }
public string AssemblyLocation { get { return m_gameres_dir.Value; } } public string AssemblyLocation { get { return m_gameres_dir.Value; } }
public string DataDirectory { get { return AssemblyLocation; } } public string DataDirectory { get { return m_gamedata_dir.Value; } }
public Exception LastError { get; set; } public Exception LastError { get; set; }
public event ParametersRequestEventHandler ParametersRequest; public event ParametersRequestEventHandler ParametersRequest;
private Lazy<string> m_gameres_dir = new Lazy<string> (() => Path.GetDirectoryName (System.Reflection.Assembly.GetExecutingAssembly().Location)); private Lazy<string> m_gameres_dir = new Lazy<string> (() => Path.GetDirectoryName (System.Reflection.Assembly.GetExecutingAssembly().Location));
private Lazy<string> m_gamedata_dir;
private FormatCatalog () private FormatCatalog ()
{ {
m_gamedata_dir = new Lazy<string> (() => Path.Combine (AssemblyLocation, "GameData"));
//An aggregate catalog that combines multiple catalogs //An aggregate catalog that combines multiple catalogs
var catalog = new AggregateCatalog(); var catalog = new AggregateCatalog();
//Adds all the parts found in the same assembly as the Program class //Adds all the parts found in the same assembly as the Program class