# HG changeset patch # User IBBoard # Date 1337111849 -3600 # Node ID 81e130f3b85ee238ff18e2cba67174b35fcdee33 # Parent b2c81883384102654c43ee7c0b6548891d1f662d Re #417: Improve install experience * Make hacked default path available (will need improving/replacing) Also: * Fix type casting issue diff -r b2c818833841 -r 81e130f3b85e API/Objects/Army.cs --- a/API/Objects/Army.cs Sat Apr 21 15:53:24 2012 +0100 +++ b/API/Objects/Army.cs Tue May 15 20:57:29 2012 +0100 @@ -301,7 +301,7 @@ requirements.AddRange(unitType.GetRequirements()); } - return requirements; + return (ICollection)requirements; } internal void OnArmyCompositionChanged() diff -r b2c818833841 -r 81e130f3b85e API/WarFoundryHacks.cs --- a/API/WarFoundryHacks.cs Sat Apr 21 15:53:24 2012 +0100 +++ b/API/WarFoundryHacks.cs Tue May 15 20:57:29 2012 +0100 @@ -16,10 +16,12 @@ /// public class WarFoundryHacks { + public static readonly string dataPath = Path.Combine(Constants.ExecutablePath, "data"); + public static void Initialise() { //Set default data path - should be a preference - WarFoundryLoader.GetDefault().AddLoadDirectory(new DirectoryInfo(Path.Combine(Constants.ExecutablePath, "data"))); + WarFoundryLoader.GetDefault().AddLoadDirectory(new DirectoryInfo(dataPath)); //Make sure we have at least one loader - should be controlled by plugins WarFoundryLoader.GetDefault().RegisterFactory(WarFoundryXmlFactory.GetFactory()); //Make sure we have a way to save files - should be controlled by plugins