I’m making a smart Camera that tracks the player. Instead of the player being in the center all the time, the camera can be smarter when the player comes to the edges of the tile map basically a bounds for the camera.
So, the camera needs to know the size of the whole map. So I’m thinking put all of the tiles in a sorting layer and get the size of the layer but I don’t know If I can’t the size of the layer or do I have to manually count the number of tiles (horizontally & vertically) or position the camera to manually get the x,y coordinates?
Or maybe there’s a camera tutorial of it already? ![]()