Major update, cleaned up code, added and renamed some functions and added a stats and admin page