From 4fed3371d0d27e391f990487f7bc4c5571a8a5e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Fri, 4 Jul 2014 17:10:44 +0200 Subject: [PATCH] avoid an unneccessary conversion FieldLoader can do --- OpenRA.Mods.RA/RallyPoint.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/OpenRA.Mods.RA/RallyPoint.cs b/OpenRA.Mods.RA/RallyPoint.cs index 737f21e647..56f3b361d3 100644 --- a/OpenRA.Mods.RA/RallyPoint.cs +++ b/OpenRA.Mods.RA/RallyPoint.cs @@ -16,7 +16,7 @@ namespace OpenRA.Mods.RA [Desc("Used to waypoint units after production or repair is finished.")] public class RallyPointInfo : ITraitInfo { - public readonly int[] RallyPoint = { 1, 3 }; + public readonly CVec RallyPoint = new CVec(1, 3); public readonly string IndicatorPalettePrefix = "player"; public object Create(ActorInitializer init) { return new RallyPoint(init.self, this); } @@ -29,7 +29,7 @@ namespace OpenRA.Mods.RA public RallyPoint(Actor self, RallyPointInfo info) { - rallyPoint = self.Location + new CVec(info.RallyPoint[0], info.RallyPoint[1]); + rallyPoint = self.Location + info.RallyPoint; self.World.AddFrameEndTask(w => w.Add(new Effects.RallyPoint(self, info.IndicatorPalettePrefix))); }