Fixed invulnerable infantry

Closes #6263
This commit is contained in:
Christopher Grant
2014-08-17 22:57:44 -04:00
committed by Oliver Brakmann
parent 6fcd4c3605
commit 774c8121c2
3 changed files with 24 additions and 11 deletions

View File

@@ -436,6 +436,19 @@ namespace OpenRA.Utility
ConvertFloatArrayToPercentArray(ref node.Value.Value);
}
if (engineVersion < 20140823)
{
if (depth == 2 && node.Key == "ArmorUpgrade" && parentKey == "GainsStatUpgrades")
node.Key = "DamageUpgrade";
if (depth == 2 && node.Key == "ArmorModifier" && parentKey == "GainsStatUpgrades")
{
node.Key = "DamageModifier";
node.Value.Value = string.Join(", ", node.Value.Value.Split(',')
.Select(s => ((int)(100 * 100 / float.Parse(s))).ToString()));
}
}
UpgradeActorRules(engineVersion, ref node.Value.Nodes, node, depth + 1);
// RemoveImmediately was replaced with RemoveOnConditions