Don't remember where I got this script, so I'm just uploading it here.