fix trailing whitespace everywhere

This commit is contained in:
Chris Forbes
2011-09-25 14:37:12 +13:00
parent 0eb98ef3b5
commit 55036cd58c
596 changed files with 3194 additions and 3194 deletions

View File

@@ -1,7 +1,7 @@
#region Copyright & License Information
/*
* Copyright 2007-2011 The OpenRA Developers (see AUTHORS)
* This file is part of OpenRA, which is free software. It is made
* This file is part of OpenRA, which is free software. It is made
* available to you under the terms of the GNU General Public License
* as published by the Free Software Foundation. For more information,
* see COPYING.
@@ -33,14 +33,14 @@ namespace OpenRA.Mods.RA.Widgets
// Queue-per-structure
var perqueue = world.Selection.Actors.FirstOrDefault(
a => a.IsInWorld && a.World.LocalPlayer == a.Owner && a.HasTrait<ProductionQueue>());
if (perqueue != null)
{
Widget.RootWidget.GetWidget<BuildPaletteWidget>("INGAME_BUILD_PALETTE")
.SetCurrentTab(perqueue.TraitsImplementing<ProductionQueue>().First());
return;
}
// Queue-per-player
var types = world.Selection.Actors.Where(a => a.IsInWorld && (a.World.LocalPlayer == a.Owner))
.SelectMany(a => a.TraitsImplementing<Production>())
@@ -48,7 +48,7 @@ namespace OpenRA.Mods.RA.Widgets
.ToArray();
if (types.Length == 0)
return;
return;
Widget.RootWidget.GetWidget<BuildPaletteWidget>("INGAME_BUILD_PALETTE")
.SetCurrentTab(world.LocalPlayer.PlayerActor.TraitsImplementing<ProductionQueue>().FirstOrDefault(t => types.Contains(t.Info.Type)));

View File

@@ -1,7 +1,7 @@
#region Copyright & License Information
/*
* Copyright 2007-2011 The OpenRA Developers (see AUTHORS)
* This file is part of OpenRA, which is free software. It is made
* This file is part of OpenRA, which is free software. It is made
* available to you under the terms of the GNU General Public License
* as published by the Free Software Foundation. For more information,
* see COPYING.

View File

@@ -1,7 +1,7 @@
#region Copyright & License Information
/*
* Copyright 2007-2011 The OpenRA Developers (see AUTHORS)
* This file is part of OpenRA, which is free software. It is made
* This file is part of OpenRA, which is free software. It is made
* available to you under the terms of the GNU General Public License
* as published by the Free Software Foundation. For more information,
* see COPYING.
@@ -30,7 +30,7 @@ namespace OpenRA.Mods.RA
}
public class SmudgeLayer: IRenderOverlay, IWorldLoaded
{
{
public SmudgeLayerInfo Info;
Dictionary<int2,TileReference<byte,byte>> tiles;
Sprite[][] smudgeSprites;
@@ -41,23 +41,23 @@ namespace OpenRA.Mods.RA
this.Info = info;
smudgeSprites = Info.Types.Select(x => Game.modData.SpriteLoader.LoadAllSprites(x)).ToArray();
}
public void WorldLoaded(World w)
{
world = w;
tiles = new Dictionary<int2,TileReference<byte,byte>>();
// Add map smudges
foreach (var s in w.Map.Smudges.Value.Where( s => Info.Types.Contains(s.Type )))
tiles.Add(s.Location,new TileReference<byte,byte>((byte)Array.IndexOf(Info.Types,s.Type),
(byte)s.Depth));
}
public void AddSmudge(int2 loc)
{
if (!world.GetTerrainInfo(loc).AcceptSmudge)
return;
if (Game.CosmeticRandom.Next(0,100) <= Info.SmokePercentage)
world.AddFrameEndTask(w => w.Add(new Smoke(w, Traits.Util.CenterOfCell(loc), Info.SmokeType)));
@@ -68,7 +68,7 @@ namespace OpenRA.Mods.RA
tiles.Add(loc, new TileReference<byte,byte>(st,(byte)0));
return;
}
var tile = tiles[loc];
// Existing smudge; make it deeper
int depth = Info.Depths[tile.type-1];
@@ -78,7 +78,7 @@ namespace OpenRA.Mods.RA
tiles[loc] = tile; // struct semantics.
}
}
public void Render( WorldRenderer wr )
{
var cliprect = Game.viewport.WorldBounds(world);