Updated x-ray script