Major refactor, working on argument handling