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.
@@ -20,19 +20,19 @@ using OpenRA.Widgets;
namespace OpenRA.Mods.RA
{
public class RALoadScreen : ILoadScreen
{
{
Dictionary<string, string> Info;
static string[] Comments = new[] { "Filling Crates...", "Charging Capacitors...", "Reticulating Splines...",
"Planting Trees...", "Building Bridges...", "Aging Empires...",
"Compiling EVA...", "Constructing Pylons...", "Activating Skynet...",
"Splitting Atoms..."
};
Stopwatch lastLoadScreen = new Stopwatch();
Rectangle StripeRect;
Sprite Stripe, Logo;
float2 LogoPos;
Renderer r;
public void Init(Dictionary<string, string> info)
{
@@ -41,7 +41,7 @@ namespace OpenRA.Mods.RA
// can display loadscreen as early as possible
r = Game.Renderer;
if (r == null) return;
var s = new Sheet("mods/ra/uibits/loadscreen.png");
Logo = new Sprite(s, new Rectangle(0,0,256,256), TextureChannel.Alpha);
Stripe = new Sprite(s, new Rectangle(256,0,256,256), TextureChannel.Alpha);
@@ -53,17 +53,17 @@ namespace OpenRA.Mods.RA
{
if (r == null)
return;
// Update text at most every 0.5 seconds
if (lastLoadScreen.ElapsedTime() < 0.5)
return;
lastLoadScreen.Reset();
var text = Comments.Random(Game.CosmeticRandom);
var textSize = r.Fonts["Bold"].Measure(text);
r.BeginFrame(float2.Zero, 1f);
WidgetUtils.FillRectWithSprite(StripeRect, Stripe);
WidgetUtils.FillRectWithSprite(StripeRect, Stripe);
r.RgbaSpriteRenderer.DrawSprite(Logo, LogoPos);
r.Fonts["Bold"].DrawText(text, new float2(Renderer.Resolution.Width - textSize.X - 20, Renderer.Resolution.Height - textSize.Y - 20), Color.White);
r.EndFrame( new NullInputHandler() );