HexMapLibrary
Public Member Functions | Private Attributes | List of all members
Wunderwunsch.HexMapLibrary.Generic.TileDataProvider< T > Class Template Reference

Public Member Functions

 TileDataProvider (Dictionary< Vector3Int, Tile< T >> tilesByPosition, TilePositionProvider tilePositionProvider)
 
Tile< T > FromCartesianCoordinate (Vector3 cartesianCoordinate)
 TODO add more description, returns null if it the input coordinate is not on the map; More...
 
Tile< T > FromTileRotated60DegreeClockwise (Vector3Int center, Vector3Int pointToRotate)
 rotates the input tile coordinate 60° Clockwise around the specified center point and returns the tile on that position. returns null if outside of map bounds More...
 
Tile< T > FromTileRotated60DegreeClockwise (Tile< T > center, Tile< T > pointToRotate)
 rotates the input tile coordinate 60° Clockwise around the specified center point and returns the tile on that position. returns null if outside of map bounds More...
 
Tile< T > FromTileRotated60DegreeCounterClockwise (Vector3Int center, Vector3Int pointToRotate)
 rotates the input tile coordinate 60° Counter-clockwise around the specified center point and returns the tile on that position. returns null if outside of map bounds More...
 
Tile< T > FromTileRotated60DegreeCounterClockwise (Tile< T > center, Tile< T > pointToRotate)
 rotates the input tile coordinate 60° Counter-clockwise around the specified center point and returns the tile on that position. returns null if outside of map bounds More...
 

Private Attributes

Dictionary< Vector3Int, Tile< T > > tilesByPosition
 
TilePositionProvider tilePositionProvider
 

Member Function Documentation

◆ FromCartesianCoordinate()

Tile<T> Wunderwunsch.HexMapLibrary.Generic.TileDataProvider< T >.FromCartesianCoordinate ( Vector3  cartesianCoordinate)

TODO add more description, returns null if it the input coordinate is not on the map;

Parameters
cartesianCoordinate
Returns

◆ FromTileRotated60DegreeClockwise() [1/2]

Tile<T> Wunderwunsch.HexMapLibrary.Generic.TileDataProvider< T >.FromTileRotated60DegreeClockwise ( Vector3Int  center,
Vector3Int  pointToRotate 
)

rotates the input tile coordinate 60° Clockwise around the specified center point and returns the tile on that position. returns null if outside of map bounds

◆ FromTileRotated60DegreeClockwise() [2/2]

Tile<T> Wunderwunsch.HexMapLibrary.Generic.TileDataProvider< T >.FromTileRotated60DegreeClockwise ( Tile< T >  center,
Tile< T >  pointToRotate 
)

rotates the input tile coordinate 60° Clockwise around the specified center point and returns the tile on that position. returns null if outside of map bounds

◆ FromTileRotated60DegreeCounterClockwise() [1/2]

Tile<T> Wunderwunsch.HexMapLibrary.Generic.TileDataProvider< T >.FromTileRotated60DegreeCounterClockwise ( Vector3Int  center,
Vector3Int  pointToRotate 
)

rotates the input tile coordinate 60° Counter-clockwise around the specified center point and returns the tile on that position. returns null if outside of map bounds

◆ FromTileRotated60DegreeCounterClockwise() [2/2]

Tile<T> Wunderwunsch.HexMapLibrary.Generic.TileDataProvider< T >.FromTileRotated60DegreeCounterClockwise ( Tile< T >  center,
Tile< T >  pointToRotate 
)

rotates the input tile coordinate 60° Counter-clockwise around the specified center point and returns the tile on that position. returns null if outside of map bounds