Move ChooseRandomCell from WorldUtils to Map

This commit is contained in:
Pavlos Touboulidis
2014-06-13 14:02:51 +03:00
parent 77fb188585
commit f0c672b70c
5 changed files with 11 additions and 10 deletions

View File

@@ -100,13 +100,6 @@ namespace OpenRA
: (edge ? w.Map.Bounds.Top : w.Map.Bounds.Bottom));
}
public static CPos ChooseRandomCell(this World w, MersenneTwister r)
{
return new CPos(
r.Next(w.Map.Bounds.Left, w.Map.Bounds.Right),
r.Next(w.Map.Bounds.Top, w.Map.Bounds.Bottom));
}
public static WRange DistanceToMapEdge(this World w, WPos pos, WVec dir)
{
var tl = w.Map.Bounds.TopLeftAsCPos().TopLeft;