I'm getting quite proficient with MessagEase now, so I'm writing this entire post on my phone while my computer runs the message deletion macro.
The script is pretty reliable. It finally finished with my probably most populated DM, and successfully deleted 8346 of 8526 messages, only missing 180. This isn't perfect, but it's good enough for me.
The script also does not remove old embeds or attachments, since it only edits the messages, but the numbers of those are small enough (< 500) that I think I can just go through and do them manually. Writing a script that works in the search interface would probably be a lot harder, since page up/down doesn't work in there.
I consider the script good enough to publish, but it's so dependant on my screen dimensions that I'll have to change it to dynamically detect and calculate things before I can make it public. That should be a fun exercise.
I have an exam on Friday which is occupying most of my brain power at the moment, despite me not actually trying to prepare for it. Tomorrow I'll go and look at some past papers for it so that I'm mildly prepared.