From 15813b04a8dea4708d4ee5eb3461fcc636155432 Mon Sep 17 00:00:00 2001 From: Chris Forbes Date: Mon, 22 Mar 2010 19:19:44 +1300 Subject: [PATCH] oops. --- OpenRA.Game/WorldUtils.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/OpenRA.Game/WorldUtils.cs b/OpenRA.Game/WorldUtils.cs index 2544476840..8be9c2d19f 100755 --- a/OpenRA.Game/WorldUtils.cs +++ b/OpenRA.Game/WorldUtils.cs @@ -82,7 +82,9 @@ namespace OpenRA public static IEnumerable FindUnits(this World world, float2 a, float2 b) { - return world.WorldActor.traits.Get().ActorsInBox(a.ToInt2(), b.ToInt2()); + var u = float2.Min(a, b).ToInt2(); + var v = float2.Max(a, b).ToInt2(); + return world.WorldActor.traits.Get().ActorsInBox(u,v); } public static IEnumerable FindUnitsInCircle(this World world, float2 a, float r)