significant refactor to get rid of static methods and make code a bit cleaner
coming along