Load mod yaml via the virtual filesystem.

This commit is contained in:
Paul Chote
2016-01-21 17:36:06 +00:00
parent 45bae7e9b3
commit 4a12e7bafc
11 changed files with 31 additions and 19 deletions

View File

@@ -21,11 +21,12 @@ namespace OpenRA.Graphics
public CursorProvider(ModData modData)
{
var sequences = new MiniYaml(null, MiniYaml.Merge(modData.Manifest.Cursors.Select(MiniYaml.FromFile)));
var sequenceYaml = MiniYaml.Merge(modData.Manifest.Cursors.Select(
s => MiniYaml.FromStream(modData.ModFiles.Open(s))));
var shadowIndex = new int[] { };
var nodesDict = sequences.ToDictionary();
var nodesDict = new MiniYaml(null, sequenceYaml).ToDictionary();
if (nodesDict.ContainsKey("ShadowIndex"))
{
Array.Resize(ref shadowIndex, shadowIndex.Length + 1);