Fix IDE0090
This commit is contained in:
@@ -320,8 +320,8 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
return new List<MiniYamlNode>()
|
||||
{
|
||||
new MiniYamlNode("InitialBaseCenter", FieldSaver.FormatValue(initialBaseCenter)),
|
||||
new MiniYamlNode("DefenseCenter", FieldSaver.FormatValue(DefenseCenter))
|
||||
new("InitialBaseCenter", FieldSaver.FormatValue(initialBaseCenter)),
|
||||
new("DefenseCenter", FieldSaver.FormatValue(DefenseCenter))
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -208,7 +208,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
return new List<MiniYamlNode>()
|
||||
{
|
||||
new MiniYamlNode("InitialBaseCenter", FieldSaver.FormatValue(initialBaseCenter))
|
||||
new("InitialBaseCenter", FieldSaver.FormatValue(initialBaseCenter))
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -508,20 +508,20 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
return new List<MiniYamlNode>()
|
||||
{
|
||||
new MiniYamlNode("Squads", "", Squads.Select(s => new MiniYamlNode("Squad", s.Serialize())).ToList()),
|
||||
new MiniYamlNode("InitialBaseCenter", FieldSaver.FormatValue(initialBaseCenter)),
|
||||
new MiniYamlNode("UnitsHangingAroundTheBase", FieldSaver.FormatValue(unitsHangingAroundTheBase
|
||||
new("Squads", "", Squads.Select(s => new MiniYamlNode("Squad", s.Serialize())).ToList()),
|
||||
new("InitialBaseCenter", FieldSaver.FormatValue(initialBaseCenter)),
|
||||
new("UnitsHangingAroundTheBase", FieldSaver.FormatValue(unitsHangingAroundTheBase
|
||||
.Where(a => !unitCannotBeOrdered(a))
|
||||
.Select(a => a.ActorID)
|
||||
.ToArray())),
|
||||
new MiniYamlNode("ActiveUnits", FieldSaver.FormatValue(activeUnits
|
||||
new("ActiveUnits", FieldSaver.FormatValue(activeUnits
|
||||
.Where(a => !unitCannotBeOrdered(a))
|
||||
.Select(a => a.ActorID)
|
||||
.ToArray())),
|
||||
new MiniYamlNode("RushTicks", FieldSaver.FormatValue(rushTicks)),
|
||||
new MiniYamlNode("AssignRolesTicks", FieldSaver.FormatValue(assignRolesTicks)),
|
||||
new MiniYamlNode("AttackForceTicks", FieldSaver.FormatValue(attackForceTicks)),
|
||||
new MiniYamlNode("MinAttackForceDelayTicks", FieldSaver.FormatValue(minAttackForceDelayTicks)),
|
||||
new("RushTicks", FieldSaver.FormatValue(rushTicks)),
|
||||
new("AssignRolesTicks", FieldSaver.FormatValue(assignRolesTicks)),
|
||||
new("AttackForceTicks", FieldSaver.FormatValue(attackForceTicks)),
|
||||
new("MinAttackForceDelayTicks", FieldSaver.FormatValue(minAttackForceDelayTicks)),
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -137,8 +137,8 @@ namespace OpenRA.Mods.Common.Traits.BotModules.Squads
|
||||
{
|
||||
var nodes = new List<MiniYamlNode>()
|
||||
{
|
||||
new MiniYamlNode("Type", FieldSaver.FormatValue(Type)),
|
||||
new MiniYamlNode("Units", FieldSaver.FormatValue(Units.Select(a => a.ActorID).ToArray()))
|
||||
new("Type", FieldSaver.FormatValue(Type)),
|
||||
new("Units", FieldSaver.FormatValue(Units.Select(a => a.ActorID).ToArray()))
|
||||
};
|
||||
|
||||
if (Target != Target.Invalid)
|
||||
|
||||
@@ -219,7 +219,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
return new List<MiniYamlNode>()
|
||||
{
|
||||
new MiniYamlNode("WaitingPowers", "", waitingPowersNodes)
|
||||
new("WaitingPowers", "", waitingPowersNodes)
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -228,8 +228,8 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
return new List<MiniYamlNode>()
|
||||
{
|
||||
new MiniYamlNode("QueuedBuildRequests", FieldSaver.FormatValue(queuedBuildRequests.ToArray())),
|
||||
new MiniYamlNode("IdleUnitCount", FieldSaver.FormatValue(idleUnitCount))
|
||||
new("QueuedBuildRequests", FieldSaver.FormatValue(queuedBuildRequests.ToArray())),
|
||||
new("IdleUnitCount", FieldSaver.FormatValue(idleUnitCount))
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user