# Tilemap corners are not working as intended (advice please)

**URL:** <https://forum.defold.com/t/tilemap-corners-are-not-working-as-intended-advice-please/68983>\
**Category:** Questions\
**Created:** [July 30, 2021, 5:04pm UTC](https://forum.defold.com/t/tilemap-corners-are-not-working-as-intended-advice-please/68983 "2021-07-30T17:04:10Z")\
**Posts on this page:** 2\
**Page:** 2

<div class="post-metadata">

**Author:** ![Mathias\_Westerdahl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/mathias_westerdahl/32/228_2.png) [@Mathias\_Westerdahl](https://forum.defold.com/u/Mathias_Westerdahl)\
**Post date:** [August 2, 2021, 7:16am UTC](https://forum.defold.com/t/tilemap-corners-are-not-working-as-intended-advice-please/68983/21 "2021-08-02T07:16:38Z")

</div>

The “tilemap.get\_tile()” won’t return a tile if the input position is “out of range” as mentioned in the error message.  
So, I’d try to check your input position before the call, e.g. by printing the position.  
I.e. if the player is outside of the tilemap, you won’t get a tile, so you’ll need to check for that.

---

<div class="post-metadata">

**Author:** ![Alexusha](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/alexusha/32/25816_2.png) [@Alexusha](https://forum.defold.com/u/Alexusha)\
**Post date:** [August 2, 2021, 4:08pm UTC](https://forum.defold.com/t/tilemap-corners-are-not-working-as-intended-advice-please/68983/22 "2021-08-02T16:08:41Z")

</div>

Ok, thank you! I think you just gave me some inspiration on how to do this! And thank you to @britzl too, for being so patient with me and helping me a lot!

[Previous page](https://forum.defold.com/t/tilemap-corners-are-not-working-as-intended-advice-please/68983.md?page=1)
