Add a comment explaining some of the sequence parsing code
This commit is contained in:
@@ -37,6 +37,15 @@ namespace OpenRA.Mods.Common.Graphics
|
|||||||
nodes.Remove("Defaults");
|
nodes.Remove("Defaults");
|
||||||
nodes = nodes.ToDictionary(kv => kv.Key, kv => MiniYaml.MergeStrict(kv.Value, defaults));
|
nodes = nodes.ToDictionary(kv => kv.Key, kv => MiniYaml.MergeStrict(kv.Value, defaults));
|
||||||
|
|
||||||
|
// Merge 'Defaults' animation image value. An example follows.
|
||||||
|
//
|
||||||
|
// - Before -
|
||||||
|
// stand:
|
||||||
|
// Facings: 8
|
||||||
|
//
|
||||||
|
// - After -
|
||||||
|
// stand: e1
|
||||||
|
// Facings: 8
|
||||||
foreach (var n in nodes)
|
foreach (var n in nodes)
|
||||||
n.Value.Value = n.Value.Value ?? defaults.Value;
|
n.Value.Value = n.Value.Value ?? defaults.Value;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user