Wiki
Clone wikiRogueSharp / RogueSharp / FieldOfView / ComputeFov
FieldOfViewComputeFov Method
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.
Namespace: RogueSharp
Assembly:
Syntax
public ReadOnlyCollection<Cell> ComputeFov( int xOrigin, int yOrigin, int radius, bool lightWalls )
Parameters
xOrigin
Type: SystemInt32
X location of the Cell to perform the field-of-view calculation with 0 as the farthest left
yOrigin
Type: SystemInt32
Y location of the Cell to perform the field-of-view calculation with 0 as the top
radius
Type: SystemInt32
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.
lightWalls
Type: SystemBoolean
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.
Return Value
Type: ReadOnlyCollectionCell
List of Cells representing the what is observable in the Map based on the specified parameters
See Also
Reference
FieldOfView Class
RogueSharp Namespace
[4]: 2014-2016 Faron Bracy
Updated