Check for undefined tiles when validating map tiles

Fixes #1051

We were only checking for tile indexes that were out of the tileset's
bounds. This overlooked tiles that were in bounds, but had no
definition. This commit remedies that.