InArea() публичный Метод

Checks if a given point is in the region's area
public InArea ( Rectangle point ) : bool
point Rectangle Point to check
Результат bool
Пример #1
0
        public bool TryGetHouseRegionAtPlayer(TSPlayer player, out string owner, out int houseIndex, out Region region)
        {
            Contract.Requires<ArgumentNullException>(player != null);

              for (int i = 0; i < TShock.Regions.Regions.Count; i++) {
            region = TShock.Regions.Regions[i];
            if (region.InArea(player.TileX, player.TileY) && this.TryGetHouseRegionData(region.Name, out owner, out houseIndex))
              return true;
              }

              owner = null;
              region = null;
              houseIndex = -1;
              return false;
        }