Renormalize line endings and fix copyright headers again.

This commit is contained in:
Paul Chote
2011-04-07 21:15:42 +12:00
parent 1a49b46af1
commit b0425aff3b
144 changed files with 8076 additions and 7746 deletions

View File

@@ -1,43 +1,43 @@
#region Copyright & License Information
#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
* available to you under the terms of the GNU General Public License
* as published by the Free Software Foundation. For more information,
* see COPYING.
*/
#endregion
using System.Drawing;
using System.Linq;
using OpenRA.Traits;
namespace OpenRA.Mods.RA
{
class SupportPowerChargeBarInfo : ITraitInfo
{
public object Create(ActorInitializer init) { return new SupportPowerChargeBar(init.self); }
}
class SupportPowerChargeBar : ISelectionBar
{
Actor self;
public SupportPowerChargeBar(Actor self) { this.self = self; }
public float GetValue()
{
// only people we like should see our charge status.
if (self.World.LocalPlayer != null && self.Owner.Stances[self.World.LocalPlayer] != Stance.Ally)
return 0;
var spm = self.Owner.PlayerActor.Trait<SupportPowerManager>();
var power = spm.GetPowersForActor(self).FirstOrDefault(sp => !sp.Disabled);
if (power == null) return 0;
return 1 - (float)power.RemainingTime / power.TotalTime;
}
public Color GetColor() { return Color.Magenta; }
}
}
*/
#endregion
using System.Drawing;
using System.Linq;
using OpenRA.Traits;
namespace OpenRA.Mods.RA
{
class SupportPowerChargeBarInfo : ITraitInfo
{
public object Create(ActorInitializer init) { return new SupportPowerChargeBar(init.self); }
}
class SupportPowerChargeBar : ISelectionBar
{
Actor self;
public SupportPowerChargeBar(Actor self) { this.self = self; }
public float GetValue()
{
// only people we like should see our charge status.
if (self.World.LocalPlayer != null && self.Owner.Stances[self.World.LocalPlayer] != Stance.Ally)
return 0;
var spm = self.Owner.PlayerActor.Trait<SupportPowerManager>();
var power = spm.GetPowersForActor(self).FirstOrDefault(sp => !sp.Disabled);
if (power == null) return 0;
return 1 - (float)power.RemainingTime / power.TotalTime;
}
public Color GetColor() { return Color.Magenta; }
}
}