Quantcast
Channel: Question and Answer » libgdx
Viewing all articles
Browse latest Browse all 434

Map coordinates to camera coordinates

$
0
0

I have a tiled map which is 3 times higher than camera. When I press on a tile, I want an actor on that tile to show up. This works if camera is not moved. If I move camera a little bit up, so the tile coordinates are greater then camera coordinates, actor is placed offscreen. Is there a way to get tile coordinates so they wil fit the camera coordinates

enter image description here

Im using libgdx if it helps.


Viewing all articles
Browse latest Browse all 434

Trending Articles