cleaned up code a bit... still have unimplemented functions. also did not implement storing transitions