Stores height data in a grid.
More...
|
| | HeightPatch (int x, int y, int width, int length) |
| | Initializes a new instance of the HeightPatch class. More...
|
| |
| bool | IsSet (int index) |
| | Checks an index to see whether or not it's height value has been set. More...
|
| |
| bool | TryGetHeight (int index, out int value) |
| | Gets the height value at a specified index. A return value indicates whether the height value is set. More...
|
| |
| bool | TryGetHeight (int x, int y, out int value) |
| | Gets the height value at a specified index. A return value indicates whether the height value is set. More...
|
| |
| void | Resize (int x, int y, int width, int length) |
| | Resizes the patch. Only works if the new size is smaller than or equal to the initial size. More...
|
| |
| void | Clear () |
| | Clears the HeightPatch by unsetting every value. More...
|
| |
| void | SetAll (int h) |
| | Sets all of the height values to the same value. More...
|
| |
|
| const int | UnsetHeight = -1 |
| | The value used when a height value has not yet been set. More...
|
| |
Stores height data in a grid.
Definition at line 11 of file HeightPatch.cs.
◆ HeightPatch()
| SharpNav.HeightPatch.HeightPatch |
( |
int |
x, |
|
|
int |
y, |
|
|
int |
width, |
|
|
int |
length |
|
) |
| |
Initializes a new instance of the HeightPatch class.
- Parameters
-
| x | The initial X coordinate of the patch. |
| y | The initial Y coordinate of the patch. |
| width | The width of the patch. |
| length | The length of the patch. |
Definition at line 28 of file HeightPatch.cs.
◆ Clear()
| void SharpNav.HeightPatch.Clear |
( |
| ) |
|
◆ IsSet()
| bool SharpNav.HeightPatch.IsSet |
( |
int |
index | ) |
|
Checks an index to see whether or not it's height value has been set.
- Parameters
-
- Returns
- A value indicating whether or not the height value at the index is set.
Definition at line 128 of file HeightPatch.cs.
◆ Resize()
| void SharpNav.HeightPatch.Resize |
( |
int |
x, |
|
|
int |
y, |
|
|
int |
width, |
|
|
int |
length |
|
) |
| |
Resizes the patch. Only works if the new size is smaller than or equal to the initial size.
- Parameters
-
| x | The new X coordinate. |
| y | The new Y coordinate. |
| width | The new width. |
| length | The new length. |
Definition at line 165 of file HeightPatch.cs.
◆ SetAll()
| void SharpNav.HeightPatch.SetAll |
( |
int |
h | ) |
|
Sets all of the height values to the same value.
- Parameters
-
| h | The height to apply to all values. |
Definition at line 189 of file HeightPatch.cs.
◆ TryGetHeight() [1/2]
| bool SharpNav.HeightPatch.TryGetHeight |
( |
int |
index, |
|
|
out int |
value |
|
) |
| |
Gets the height value at a specified index. A return value indicates whether the height value is set.
- Parameters
-
| index | The index to use. |
| value | Contains the height at the value. |
- Returns
- A value indicating whether the value at the specified index is set.
Definition at line 139 of file HeightPatch.cs.
◆ TryGetHeight() [2/2]
| bool SharpNav.HeightPatch.TryGetHeight |
( |
int |
x, |
|
|
int |
y, |
|
|
out int |
value |
|
) |
| |
Gets the height value at a specified index. A return value indicates whether the height value is set.
- Parameters
-
| x | The X coordinate. |
| y | The Y coordinate. |
| value | Contains the height at the value. |
- Returns
- A value indicating whether the value at the specified index is set.
Definition at line 152 of file HeightPatch.cs.
◆ UnsetHeight
| const int SharpNav.HeightPatch.UnsetHeight = -1 |
|
static |
The value used when a height value has not yet been set.
Definition at line 16 of file HeightPatch.cs.
◆ Length
| int SharpNav.HeightPatch.Length |
|
get |
◆ this[int index]
| int SharpNav.HeightPatch.this[int index] |
|
getset |
Gets or sets the height at a specified index.
- Parameters
-
| index | The index inside the patch. |
- Returns
- The height at the specified index.
Definition at line 91 of file HeightPatch.cs.
◆ this[int x, int y]
| int SharpNav.HeightPatch.this[int x, int y] |
|
getset |
Gets or sets the height at a specified coordinate (x, y).
- Parameters
-
| x | The X coordinate. |
| y | The Y coordinate. |
- Returns
- The height at the specified index.
Definition at line 110 of file HeightPatch.cs.
◆ Width
| int SharpNav.HeightPatch.Width |
|
get |
| int SharpNav.HeightPatch.X |
|
get |
Gets the X coordinate of the patch.
Definition at line 45 of file HeightPatch.cs.
| int SharpNav.HeightPatch.Y |
|
get |
Gets the Y coordinate of the patch.
Definition at line 56 of file HeightPatch.cs.
The documentation for this class was generated from the following file:
- C:/gamedev/unity/DA20.1X/Assets/CodeRespawn/DungeonArchitect/ThirdParty/SharpNav/HeightPatch.cs