Well I dont know if you've had a chance to look at the code but the script assumes there is only one username and password, 1 connection, and that the files are being moved from the local server to a remote server. It seems to me that it would require major modifications to get it to work oppositely, where it grabs the files off of a remote server and then downloads them to the local server.
There has to be a script out there that does this though, I cant believe I havent had more replies or found other scripts yet.