Minor style fixes.

This commit is contained in:
Paul Chote
2014-09-29 20:58:09 +13:00
parent f463407d8d
commit 7bc8c171e8

View File

@@ -62,6 +62,7 @@ namespace OpenRA.GameRules
[FieldLoader.LoadUsing("LoadProjectile")]
public readonly IProjectileInfo Projectile;
[FieldLoader.LoadUsing("LoadWarheads")]
public readonly List<Warhead> Warheads = new List<Warhead>();
@@ -153,12 +154,10 @@ namespace OpenRA.GameRules
foreach (var warhead in Warheads)
{
var wh = warhead; // force the closure to bind to the current warhead
Action a;
a = () => wh.DoImpact(target, firedBy, damageModifiers);
Action a = () => wh.DoImpact(target, firedBy, damageModifiers);
if (wh.Delay > 0)
firedBy.World.AddFrameEndTask(
w => w.Add(new DelayedAction(wh.Delay, a)));
firedBy.World.AddFrameEndTask(w => w.Add(new DelayedAction(wh.Delay, a)));
else
a();
}