Reorganized some files, replaced DNS lookup with my own function, will do more reorganizing soon