Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: get tile coord from SKTile object #42

Open
ghost opened this issue May 6, 2022 · 0 comments
Open

Feature request: get tile coord from SKTile object #42

ghost opened this issue May 6, 2022 · 0 comments

Comments

@ghost
Copy link

ghost commented May 6, 2022

While it is easy to get the tiles using tileAt(coord: tileCoord) from the SKTilemap or SKTileLayer, there is no reverse method that gives me the coords for any given SKTile.

I would like to be able to get the coords from the SKTile itself.

(I could calculate them myself my using something like tilemap.coordinateForPoint(tile.position) but that seems complicated and may not be accurate depending on the parent node of the tile.)

thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants