Transforms input from screen point to world point.
This commit is contained in:
@@ -55,8 +55,7 @@ namespace Cryville.Common.Unity.Input {
|
||||
}
|
||||
void Update() {
|
||||
double time = Time.timeAsDouble;
|
||||
Vector2 pos = unity::Input.mousePosition;
|
||||
pos.y = Screen.height - pos.y;
|
||||
Vector3 pos = UnityCameraUtils.ScreenToWorldPoint(unity::Input.mousePosition);
|
||||
handler.Feed(0, 0, new InputVector(time, pos));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user