fix indents everywhere

This commit is contained in:
Chris Forbes
2011-10-18 15:10:17 +13:00
parent 227bbc109e
commit bc6af1841b
180 changed files with 2707 additions and 2707 deletions

View File

@@ -33,10 +33,10 @@ namespace OpenRA.Mods.RA.Effects
public readonly int RangeLimit = 0;
public readonly bool TurboBoost = false;
public readonly int TrailInterval = 2;
public readonly int ContrailLength = 0;
public readonly Color ContrailColor = Color.White;
public readonly bool ContrailUsePlayerColor = false;
public readonly int ContrailDelay = 1;
public readonly int ContrailLength = 0;
public readonly Color ContrailColor = Color.White;
public readonly bool ContrailUsePlayerColor = false;
public readonly int ContrailDelay = 1;
public IEffect Create(ProjectileArgs args) { return new Missile( this, args ); }
}
@@ -54,33 +54,33 @@ namespace OpenRA.Mods.RA.Effects
int Facing;
int t;
int Altitude;
ContrailHistory Trail;
ContrailHistory Trail;
public Missile(MissileInfo info, ProjectileArgs args)
{
Info = info;
Args = args;
public Missile(MissileInfo info, ProjectileArgs args)
{
Info = info;
Args = args;
SubPxPosition = 1024 * Args.src;
Altitude = Args.srcAltitude;
Facing = Args.facing;
SubPxPosition = 1024 * Args.src;
Altitude = Args.srcAltitude;
Facing = Args.facing;
if (info.Inaccuracy > 0)
offset = (info.Inaccuracy * args.firedBy.World.SharedRandom.Gauss2D(2)).ToInt2();
if (info.Inaccuracy > 0)
offset = (info.Inaccuracy * args.firedBy.World.SharedRandom.Gauss2D(2)).ToInt2();
if (Info.Image != null)
{
anim = new Animation(Info.Image, () => Facing);
anim.PlayRepeating("idle");
}
if (Info.Image != null)
{
anim = new Animation(Info.Image, () => Facing);
anim.PlayRepeating("idle");
}
if (Info.ContrailLength > 0)
{
Trail = new ContrailHistory(Info.ContrailLength,
Info.ContrailUsePlayerColor ? ContrailHistory.ChooseColor(args.firedBy) : Info.ContrailColor,
Info.ContrailDelay);
}
}
if (Info.ContrailLength > 0)
{
Trail = new ContrailHistory(Info.ContrailLength,
Info.ContrailUsePlayerColor ? ContrailHistory.ChooseColor(args.firedBy) : Info.ContrailColor,
Info.ContrailDelay);
}
}
// In pixels
const int MissileCloseEnough = 7;
@@ -140,8 +140,8 @@ namespace OpenRA.Mods.RA.Effects
Explode(world);
}
if (Trail != null)
Trail.Tick(PxPosition - new float2(0,Altitude));
if (Trail != null)
Trail.Tick(PxPosition - new float2(0,Altitude));
}
void Explode(World world)
@@ -154,12 +154,12 @@ namespace OpenRA.Mods.RA.Effects
public IEnumerable<Renderable> Render()
{
if (Args.firedBy.World.LocalShroud.IsVisible(OpenRA.Traits.Util.CellContaining(PxPosition.ToFloat2())))
yield return new Renderable(anim.Image,PxPosition.ToFloat2() - 0.5f * anim.Image.size - new float2(0, Altitude),
Args.weapon.Underwater ? "shadow" : "effect", PxPosition.Y);
if (Args.firedBy.World.LocalShroud.IsVisible(OpenRA.Traits.Util.CellContaining(PxPosition.ToFloat2())))
yield return new Renderable(anim.Image,PxPosition.ToFloat2() - 0.5f * anim.Image.size - new float2(0, Altitude),
Args.weapon.Underwater ? "shadow" : "effect", PxPosition.Y);
if (Trail != null)
Trail.Render(Args.firedBy);
if (Trail != null)
Trail.Render(Args.firedBy);
}
}
}