Added way to ensure validity of tile.

Should help reduce crashing. Also fixed dumb string check...