added new features to both scripts, huge cleanup

everything is just better in general, actually