Add support for random sounds to AmbientSound

This commit is contained in:
reaperrr
2017-04-22 13:05:51 +02:00
parent d9eb224c77
commit 1e63013eb1
6 changed files with 16 additions and 9 deletions

View File

@@ -596,6 +596,11 @@ namespace OpenRA.Mods.Common.UtilityCommands
RenameNodeKey(node, "-AcceptsDeliveredCash");
}
// Add random sound support to AmbientSound
if (engineVersion < 20170422)
if (node.Key == "SoundFile" && parent.Key.StartsWith("AmbientSound", StringComparison.Ordinal))
RenameNodeKey(node, "SoundFiles");
UpgradeActorRules(modData, engineVersion, ref node.Value.Nodes, node, depth + 1);
}