Skip to content

Commit

Permalink
#153 mouse cursor issues in vicinity of trees
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisforbes committed May 5, 2010
1 parent 1c50ec1 commit c6ab4be
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions OpenRA.Game/Actor.cs
Expand Up @@ -123,12 +123,10 @@ public Order Order( int2 xy, MouseInput mi )

if (!World.Map.IsInMap(xy.X, xy.Y))
return null;

var underCursor = World.FindUnitsAtMouse(mi.Location).FirstOrDefault();

if (underCursor != null && !underCursor.traits.Contains<Selectable>())
underCursor = null;

var underCursor = World.FindUnitsAtMouse(mi.Location)
.FirstOrDefault(a => a.traits.Contains<Selectable>());

return traits.WithInterface<IIssueOrder>()
.Select( x => x.IssueOrder( this, xy, mi, underCursor ) )
.FirstOrDefault( x => x != null );
Expand Down

0 comments on commit c6ab4be

Please sign in to comment.