StyleCop clean OpenRA.Game
This commit is contained in:
@@ -23,7 +23,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
public readonly int Cooldown = 0;
|
||||
public readonly int InitialDelay = 0;
|
||||
|
||||
public object Create(ActorInitializer init) { return new BaseProvider(init.self, this); }
|
||||
public object Create(ActorInitializer init) { return new BaseProvider(init.Self, this); }
|
||||
}
|
||||
|
||||
public class BaseProvider : ITick, IPostRenderSelection, ISelectionBar
|
||||
|
||||
@@ -19,7 +19,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
public readonly string Palette = "terrain";
|
||||
public readonly bool HasMinibib = false;
|
||||
|
||||
public object Create(ActorInitializer init) { return new Bib(init.self, this); }
|
||||
public object Create(ActorInitializer init) { return new Bib(init.Self, this); }
|
||||
}
|
||||
|
||||
public class Bib : INotifyAddedToWorld, INotifyRemovedFromWorld
|
||||
|
||||
@@ -127,14 +127,14 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
public Building(ActorInitializer init, BuildingInfo info)
|
||||
{
|
||||
this.self = init.self;
|
||||
this.self = init.Self;
|
||||
this.topLeft = init.Get<LocationInit, CPos>();
|
||||
this.Info = info;
|
||||
|
||||
occupiedCells = FootprintUtils.UnpathableTiles(self.Info.Name, Info, TopLeft)
|
||||
.Select(c => Pair.New(c, SubCell.FullCell)).ToArray();
|
||||
|
||||
CenterPosition = init.world.Map.CenterOfCell(topLeft) + FootprintUtils.CenterOffset(init.world, Info);
|
||||
CenterPosition = init.World.Map.CenterOfCell(topLeft) + FootprintUtils.CenterOffset(init.World, Info);
|
||||
SkipMakeAnimation = init.Contains<SkipMakeAnimsInit>();
|
||||
}
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
[Desc("A dictionary of buildings placed on the map. Attach this to the world actor.")]
|
||||
public class BuildingInfluenceInfo : ITraitInfo
|
||||
{
|
||||
public object Create(ActorInitializer init) { return new BuildingInfluence(init.world); }
|
||||
public object Create(ActorInitializer init) { return new BuildingInfluence(init.World); }
|
||||
}
|
||||
|
||||
public class BuildingInfluence
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
{
|
||||
public readonly int LingerTime = 20;
|
||||
|
||||
public object Create(ActorInitializer init) { return new DeadBuildingState(init.self, this); }
|
||||
public object Create(ActorInitializer init) { return new DeadBuildingState(init.Self, this); }
|
||||
}
|
||||
|
||||
class DeadBuildingState : INotifyKilled
|
||||
|
||||
@@ -38,13 +38,13 @@ namespace OpenRA.Mods.Common.Traits
|
||||
if (init.Contains<FreeActorInit>() && !init.Get<FreeActorInit>().ActorValue)
|
||||
return;
|
||||
|
||||
init.self.World.AddFrameEndTask(w =>
|
||||
init.Self.World.AddFrameEndTask(w =>
|
||||
{
|
||||
var a = w.CreateActor(info.Actor, new TypeDictionary
|
||||
{
|
||||
new ParentActorInit(init.self),
|
||||
new LocationInit(init.self.Location + info.SpawnOffset),
|
||||
new OwnerInit(init.self.Owner),
|
||||
new ParentActorInit(init.Self),
|
||||
new LocationInit(init.Self.Location + info.SpawnOffset),
|
||||
new OwnerInit(init.Self.Owner),
|
||||
new FacingInit(info.Facing),
|
||||
});
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
public readonly CVec RallyPoint = new CVec(1, 3);
|
||||
public readonly string IndicatorPalettePrefix = "player";
|
||||
|
||||
public object Create(ActorInitializer init) { return new RallyPoint(init.self, this); }
|
||||
public object Create(ActorInitializer init) { return new RallyPoint(init.Self, this); }
|
||||
}
|
||||
|
||||
public class RallyPoint : IIssueOrder, IResolveOrder, ISync
|
||||
|
||||
Reference in New Issue
Block a user