/// <summary> /// Performs a field-of-view calculation with the specified parameters. /// Field-of-view (FOV) is basically a calculation of what is observable in the Map from a given Cell with a given light radius. /// Any existing field-of-view calculations will be overwritten when calling this method. /// </summary> /// <param name="xOrigin">X location of the Cell to perform the field-of-view calculation with 0 as the farthest left</param> /// <param name="yOrigin">Y location of the Cell to perform the field-of-view calculation with 0 as the top</param> /// <param name="radius">The number of Cells in which the field-of-view extends from the origin Cell. Think of this as the intensity of the light source.</param> /// <param name="lightWalls">True if walls should be included in the field-of-view when they are within the radius of the light source. False excludes walls even when they are within range.</param> public void ComputeFov(int xOrigin, int yOrigin, int radius, bool lightWalls) { _fieldOfView.ComputeFov(xOrigin, yOrigin, radius, lightWalls); }
/// <summary> /// Performs a field-of-view calculation with the specified parameters. /// Field-of-view (FOV) is basically a calculation of what is observable in the Map from a given Cell with a given light radius. /// Any existing field-of-view calculations will be overwritten when calling this method. /// </summary> /// <param name="xOrigin">X location of the Cell to perform the field-of-view calculation with 0 as the farthest left</param> /// <param name="yOrigin">Y location of the Cell to perform the field-of-view calculation with 0 as the top</param> /// <param name="radius">The number of Cells in which the field-of-view extends from the origin Cell. Think of this as the intensity of the light source.</param> /// <param name="lightWalls">True if walls should be included in the field-of-view when they are within the radius of the light source. False excludes walls even when they are within range.</param> /// <returns>List of Cells representing what is observable in the Map based on the specified parameters</returns> public ReadOnlyCollection <ICell> ComputeFov(int xOrigin, int yOrigin, int radius, bool lightWalls) { return(_fieldOfView.ComputeFov(xOrigin, yOrigin, radius, lightWalls)); }