Thanks for the tip Jon! That worked flawlessly.
The DirFlatten tool also worked perfectly for what I wanted, but as it worked with the built-in tools it makes no sense in using a separate application. I will use it at work where I don't have my DOpus though
Here's the "final" version of the script for anyone that might search for the same solution on how to move all files from a subfolder:
SET flatview=MixedNoFolders
SELECT ALLFILES
COPY MOVE HERE FLATVIEWCOPY=single
SET flatview=off
SELECT ALLDIRS
I also made it select all directories to make them easier to delete afterwards, but I didn't want to delete the folders themselves (if an error were to occur)