Kill Util.Centered

This commit is contained in:
Paul Chote
2011-05-04 09:21:30 +12:00
parent 71f79ad068
commit 6495478433
4 changed files with 10 additions and 21 deletions

View File

@@ -96,14 +96,6 @@ namespace OpenRA.Traits
public static float2 RelOffset(this int[] offset) { return new float2(offset[0], offset[1]); }
public static float2 AbsOffset(this int[] offset) { return new float2(offset.ElementAtOrDefault(2), offset.ElementAtOrDefault(3)); }
public static Renderable Centered(Actor self, Sprite s, float2 location)
{
var pal = "player{0}".F(self.Owner == null ? 0 : self.Owner.Index);
var loc = location - 0.5f * s.size;
return new Renderable(s, loc.Round(), pal, (int)self.CenterLocation.Y);
}
public static Activity SequenceActivities(params Activity[] acts)
{
return acts.Reverse().Aggregate(