EDIT: I have looked into it more, and realized that it was because overscan was disabled. I neglected to remember this for some reason, but I have fixed it.
Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first