Fix tiles bug