Fix StyleCop warnings in OpenRA.Mods.RA

This commit is contained in:
Hellhake
2015-01-01 23:03:55 +01:00
parent e9989496c4
commit b6410bc1e0
134 changed files with 261 additions and 267 deletions

View File

@@ -114,10 +114,11 @@ namespace OpenRA.Mods.RA.Traits
{
if (!preventDock)
{
harv.QueueActivity(new CallFunc( () => dockedHarv = harv, false));
harv.QueueActivity(new CallFunc(() => dockedHarv = harv, false));
harv.QueueActivity(DockSequence(harv, self));
harv.QueueActivity(new CallFunc( () => dockedHarv = null, false));
harv.QueueActivity(new CallFunc(() => dockedHarv = null, false));
}
harv.QueueActivity(new CallFunc(() => harv.Trait<Harvester>().ContinueHarvesting(harv)));
}

View File

@@ -8,10 +8,10 @@
*/
#endregion
using System.Linq;
using System.Collections.Generic;
using OpenRA.Traits;
using System.Linq;
using OpenRA.Mods.Common.Orders;
using OpenRA.Traits;
namespace OpenRA.Mods.RA.Traits
{

View File

@@ -12,8 +12,8 @@ using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using OpenRA.Mods.RA.Effects;
using OpenRA.Mods.Common.Traits;
using OpenRA.Mods.RA.Effects;
using OpenRA.Traits;
namespace OpenRA.Mods.RA.Traits
@@ -42,7 +42,7 @@ namespace OpenRA.Mods.RA.Traits
public bool RepairActive = false;
public RepairableBuilding(Actor self, RepairableBuildingInfo info)
: base (info)
: base(info)
{
Health = self.Trait<Health>();
}

View File

@@ -38,11 +38,10 @@ namespace OpenRA.Mods.RA.Traits
// NOTE: we really dont care about the GC eating DisposableActions that apply to a world *other* than
// the one we're playing in.
return new DisposableAction(
() => { reservedFor = null; reservedForAircraft = null; },
() => Game.RunAfterTick(
() => { if (Game.IsCurrentWorld( self.World )) throw new InvalidOperationException(
() => { if (Game.IsCurrentWorld(self.World)) throw new InvalidOperationException(
"Attempted to finalize an undisposed DisposableAction. {0} ({1}) reserved {2} ({3})"
.F(forActor.Info.Name, forActor.ActorID, self.Info.Name, self.ActorID)); }));
}