Hundreds of features to explore
Games made in Construct
Your questions answered
Trusted by schools and universities worldwide
Free education resources to use in the classroom
Students do not need accounts with us
What we believe
We are in this together
World class complete documentation
Official and community submitted guides
Learn and share with other game developers
Upload and play games from the Construct community
Game development stories & opinions
I am trying to find the first tile in the tilemap that is tile number 21, thing is, I cant find a way to find its position!
If tile.21 exist anywhere, get the first tile.21's X Position.
Thank you for any help!
Develop games in your browser. Powerful, performant & highly capable.
I'm not sure what method you're using, but here's a capx that shows you how to find a tile with a given ID and return it's position.
https://www.dropbox.com/s/mj8zp6tyy0k5g ... .capx?dl=0
For checking if a given tile exist, there are several ways to do that. You may do a similar loop or, if you're storing the tilemap in an array you could check it even easier with the Array>Contains value condition.
Hope this helps. Cheers!