2D Toolkit Forum
2D Toolkit => Support => Topic started by: jorgar on July 03, 2016, 04:00:45 pm
-
Hi, what is the equivalent of Camera.WorldToScreenPoint() with a tk2dCamera? I've reading the documentation but i don't see any similar method.
-
Anyone know? :(
What I'm trying to do is get the Touch.position and translate a gameobject to that position. Touch.position returns screen space but i have to give to gameobject the position in world space values. With a normal camera i would use camera.WorldToScreenPoint but with a tk2dCamera it seems doesn't work.
-
tk2dCamera has a Camera component on the same game object, just get the camera component and call WorldToScreenPoint on it.
-
Thank you for answer! I didn't get the camera component. Now is working, thank you!