Esempio n. 1
0
 //Checks to see if a component such as the tower is on the path
 public bool OnPath(WorldLocation location)
 {
     foreach (var pathLocation in _path)
     {
         if (location.Equals(pathLocation))
         {
             return(true);
         }
     }
     return(false);
 }
 //Checks to see if the location is within range
 public bool InRangeOf(WorldLocation location, int range)
 {
     return(DistanceTo(location) <= range);
 }