HexMapLibrary
|
Updates every frame with the position of the mouse cursor on the XZ-Plane in different coordinate systems. More...
Public Member Functions | |
virtual void | Update () |
Update is called once per frame More... | |
void | Init (HexMap hexMap) |
Call this at start of game or when the map changes to assign the HexMap More... | |
Properties | |
bool | CursorIsOnMap [get, private set] |
Indicates whether the cursor is on the map. More... | |
Vector3 | CartesianCoordInfiniteGrid [get, private set] |
cartesian coordinate without map wrap considered More... | |
Vector3 | CartesianCoordWrapped [get, private set] |
cartesian coordinate with map wrap considered More... | |
Vector3Int | CubeCoordRaw [get, private set] |
cube coordinate without map wrap More... | |
Vector3Int | TileCoord [get, private set] |
cube coordinate with map wrap More... | |
Vector2Int | OffsetCoordInfiniteGrid [get, private set] |
offset coordinate without map wrap More... | |
Vector2Int | OffsetCoord [get, private set] |
offset coordinate with map wrap More... | |
Vector3Int | ClosestEdgeCoordInfiniteGrid [get, private set] |
closest edge coordinate without map wrap More... | |
Vector3Int | ClosestEdgeCoord [get, private set] |
closest edge coordinate with map wrap More... | |
Ray | SelectionRay [get, private set] |
equals Camera.main.ScreenPointToRay(Input.mousePosition); More... | |
Vector3Int | ClosestCornerCoordInfiniteGrid [get, private set] |
closest corner coordinate without map wrap More... | |
Vector3Int | ClosestCornerCoord [get, private set] |
closest corner coordinate with map wrap More... | |
Private Member Functions | |
Vector3 | GetPlanePosition () |
returns the cartesian of the mouse, using the active Camera and casting a ray on the XZ-plane More... | |
void | UpdateMousePositionData () |
updates all the mouse position data More... | |
Private Attributes | |
HexMap | hexMap |
Map which is assigned to the mouse - should always be the current visible map in cases where you have multiple maps. if it is null then it will just skip map wrapping and clamping. More... | |
Plane | plane |
collision plane to cast rays against to get mouse position; More... | |
Updates every frame with the position of the mouse cursor on the XZ-Plane in different coordinate systems.
|
virtual |
Update is called once per frame
void Wunderwunsch.HexMapLibrary.HexMouse.Init | ( | HexMap | hexMap | ) |
Call this at start of game or when the map changes to assign the HexMap
|
private |
returns the cartesian of the mouse, using the active Camera and casting a ray on the XZ-plane
|
private |
updates all the mouse position data
|
private |
Map which is assigned to the mouse - should always be the current visible map in cases where you have multiple maps. if it is null then it will just skip map wrapping and clamping.
|
private |
collision plane to cast rays against to get mouse position;
|
getprivate set |
Indicates whether the cursor is on the map.
|
getprivate set |
cartesian coordinate without map wrap considered
|
getprivate set |
cartesian coordinate with map wrap considered
|
getprivate set |
cube coordinate without map wrap
|
getprivate set |
cube coordinate with map wrap
|
getprivate set |
offset coordinate without map wrap
|
getprivate set |
offset coordinate with map wrap
|
getprivate set |
closest edge coordinate without map wrap
|
getprivate set |
closest edge coordinate with map wrap
|
getprivate set |
equals Camera.main.ScreenPointToRay(Input.mousePosition);
|
getprivate set |
closest corner coordinate without map wrap
|
getprivate set |
closest corner coordinate with map wrap