2D Toolkit Forum
2D Toolkit => Support => Topic started by: gabriel on May 07, 2015, 05:16:29 pm
-
I'm new using 2d Toolkit and I can't seem to find it. myMainCamera.ScreenToWorldPoint() is not valid ... And I must be blind...
I'm trying my make my camera draggable and the use of camera Overrides and ZoomFactor make it tedious to calculate modifications to Screen/World relations.
If ScreenToWorldPoint() is not a valid function on a tk2dCamera, what I'm I missing?
-
Nevermind. I found it. :)
myCamera.ScreenCamera.ScreenToWorldPoint()
-
tk2dCamera simply manipulates a Unity camera, so tk2dCamera.ScreenCamera or tk2dCamera.camera, or just GetComponent<Camera> will do the job.