Cleaned up files, scripts and databases

I've cleaned up the code a bit, as well as put in more generalized scripts and databases.