Quantcast
Viewing latest article 7
Browse Latest Browse All 68

get screen width and height in world size

Hello everyone, if i have a game with a resolution 800x600, how to make a condition to check if some object is out of the screen ? in other term i want to convert the 800 and 600 to the transform unit (basically it's always a small number) i tried doing this : print (Camera.main.ScreenToWorldPoint(new Vector3(800,600,0))); but the result is always : (0.0, -0.1, -2.8) thank you

Viewing latest article 7
Browse Latest Browse All 68

Trending Articles