A DijkstraAtlas object holds DijkstraGrid objects for each tile.
More...
|
| bool | HasPath< T > (T[,] grid, T startTile, T destinationTile) |
| | Is there a path between two tiles.
|
| |
| T | GetNextTile< T > (T[,] grid, T startTile, T destinationTile) |
| | Get the next tile on the path between a start tile and a destination tile.
|
| |
| TileDirection | GetNextDirection< T > (T[,] grid, T startTile, T destinationTile) |
| | Get the next tile on the path between a start tile and a destination tile.
|
| |
| float | GetDistanceBetweenTiles< T > (T[,] grid, T startTile, T destinationTile) |
| | Get the distance between two tiles.
|
| |
| T[] | GetPath< T > (T[,] grid, T startTile, T destinationTile, bool includeStart=true, bool includeDestination=true) |
| | Get all the tiles on the path from a start tile to a destination tile. If there is no path between the two tiles then an empty array will be returned.
|
| |
| byte[] | ToByteArray () |
| | Serializes a DijkstraAtlas to a byte array.
|
| |
| Task< byte[]> | ToByteArrayAsync (IProgress< float > progress=null, CancellationToken cancelToken=default) |
| | Asynchronously serializes a DijkstraAtlas to a byte array.
|
| |
| async Awaitable< byte[]> | ToByteArrayAwaitable (IProgress< float > progress=null, CancellationToken cancelToken=default) |
| | Asynchronously serializes a DijkstraAtlas to a byte array.
|
| |
|
| static DijkstraAtlas | FromByteArray< T > (T[,] grid, byte[] bytes) |
| | Deserializes a DijkstraAtlas from a byte array.
|
| |
| static Task< DijkstraAtlas > | FromByteArrayAsync< T > (T[,] grid, byte[] bytes, IProgress< float > progress=null, CancellationToken cancelToken=default) |
| | Asynchronously deserializes a DijkstraAtlas from a byte array.
|
| |
| static async Awaitable< DijkstraAtlas > | FromByteArrayAwaitable< T > (T[,] grid, byte[] bytes, IProgress< float > progress=null, CancellationToken cancelToken=default) |
| | Asynchronously deserializes a DijkstraAtlas from a byte array.
|
| |
A DijkstraAtlas object holds DijkstraGrid objects for each tile.
◆ FromByteArray< T >()
| static DijkstraAtlas Caskev.GridToolkit.DijkstraAtlas.FromByteArray< T > |
( |
T |
grid[,], |
|
|
byte[] |
bytes |
|
) |
| |
|
static |
Deserializes a DijkstraAtlas from a byte array.
- Parameters
-
| grid | The user grid. |
| bytes | The serialized DijkstraAtlas. |
- Returns
- The deserialized DijkstraAtlas.
◆ FromByteArrayAsync< T >()
| static Task< DijkstraAtlas > Caskev.GridToolkit.DijkstraAtlas.FromByteArrayAsync< T > |
( |
T |
grid[,], |
|
|
byte[] |
bytes, |
|
|
IProgress< float > |
progress = null, |
|
|
CancellationToken |
cancelToken = default |
|
) |
| |
|
static |
Asynchronously deserializes a DijkstraAtlas from a byte array.
- Parameters
-
| grid | The user grid. |
| bytes | The serialized DijkstraAtlas. |
| progress | An optional IProgress object to get the deserialization progression |
| cancelToken | An optional CancellationToken object to cancel the deserialization |
- Returns
- The deserialized DijkstraAtlas.
◆ FromByteArrayAwaitable< T >()
| static async Awaitable< DijkstraAtlas > Caskev.GridToolkit.DijkstraAtlas.FromByteArrayAwaitable< T > |
( |
T |
grid[,], |
|
|
byte[] |
bytes, |
|
|
IProgress< float > |
progress = null, |
|
|
CancellationToken |
cancelToken = default |
|
) |
| |
|
static |
Asynchronously deserializes a DijkstraAtlas from a byte array.
- Parameters
-
| grid | The user grid. |
| bytes | The serialized DijkstraAtlas. |
| progress | An optional IProgress object to get the deserialization progression |
| cancelToken | An optional CancellationToken object to cancel the deserialization |
- Returns
- The deserialized DijkstraAtlas.
◆ GetDistanceBetweenTiles< T >()
| float Caskev.GridToolkit.DijkstraAtlas.GetDistanceBetweenTiles< T > |
( |
T |
grid[,], |
|
|
T |
startTile, |
|
|
T |
destinationTile |
|
) |
| |
Get the distance between two tiles.
- Parameters
-
| grid | The user grid |
| startTile | The start tile |
| destinationTile | The destination tile |
- Returns
- The distance between the two tiles.
◆ GetNextDirection< T >()
| TileDirection Caskev.GridToolkit.DijkstraAtlas.GetNextDirection< T > |
( |
T |
grid[,], |
|
|
T |
startTile, |
|
|
T |
destinationTile |
|
) |
| |
Get the next tile on the path between a start tile and a destination tile.
- Parameters
-
| grid | The user grid |
| startTile | The start tile |
| destinationTile | The destination tile |
- Returns
- A Vector2Int direction
◆ GetNextTile< T >()
| T Caskev.GridToolkit.DijkstraAtlas.GetNextTile< T > |
( |
T |
grid[,], |
|
|
T |
startTile, |
|
|
T |
destinationTile |
|
) |
| |
Get the next tile on the path between a start tile and a destination tile.
- Parameters
-
| grid | The user grid |
| startTile | The start tile |
| destinationTile | The destination tile |
- Returns
- A tile object
◆ GetPath< T >()
| T[] Caskev.GridToolkit.DijkstraAtlas.GetPath< T > |
( |
T |
grid[,], |
|
|
T |
startTile, |
|
|
T |
destinationTile, |
|
|
bool |
includeStart = true, |
|
|
bool |
includeDestination = true |
|
) |
| |
Get all the tiles on the path from a start tile to a destination tile. If there is no path between the two tiles then an empty array will be returned.
- Parameters
-
| grid | The user grid |
| startTile | The start tile |
| destinationTile | The destination tile |
| includeStart | Include the start tile into the resulting array or not. Default is true |
| includeDestination | Include the target tile into the resulting array or not |
- Returns
- An array of tiles
◆ HasPath< T >()
| bool Caskev.GridToolkit.DijkstraAtlas.HasPath< T > |
( |
T |
grid[,], |
|
|
T |
startTile, |
|
|
T |
destinationTile |
|
) |
| |
Is there a path between two tiles.
- Parameters
-
| grid | The user grid |
| startTile | The start tile |
| destinationTile | The destination tile |
- Returns
- A boolean value
◆ ToByteArray()
| byte[] Caskev.GridToolkit.DijkstraAtlas.ToByteArray |
( |
| ) |
|
Serializes a DijkstraAtlas to a byte array.
- Returns
- The serialized DijkstraAtlas.
◆ ToByteArrayAsync()
| Task< byte[]> Caskev.GridToolkit.DijkstraAtlas.ToByteArrayAsync |
( |
IProgress< float > |
progress = null, |
|
|
CancellationToken |
cancelToken = default |
|
) |
| |
Asynchronously serializes a DijkstraAtlas to a byte array.
- Parameters
-
| progress | An optional IProgress object to get the deserialization progression |
| cancelToken | An optional CancellationToken object to cancel the serialization |
- Returns
- The serialized DijkstraAtlas.
◆ ToByteArrayAwaitable()
| async Awaitable< byte[]> Caskev.GridToolkit.DijkstraAtlas.ToByteArrayAwaitable |
( |
IProgress< float > |
progress = null, |
|
|
CancellationToken |
cancelToken = default |
|
) |
| |
Asynchronously serializes a DijkstraAtlas to a byte array.
- Parameters
-
| progress | An optional IProgress object to get the deserialization progression |
| cancelToken | An optional CancellationToken object to cancel the serialization |
- Returns
- The serialized DijkstraAtlas.
The documentation for this class was generated from the following file: