major update, adding 600 + lines of code