Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | GuilhermeA |
I want to get my x and y coordinates reporting an index.
For example, I have an image of 500 x 500, and tiles of 50 x 50, so I have 10 tiles in the rows and 10 in the columns, then having 100 tiles of 50x50 in all.
So if I wanted to get my tile 10, I would create a Rect2(0, 50, 50, 50), assuming it starts at 0,0!
More than mathematical formula or gdscript method I can use for this