fixing tile indexes