Full state machine in place, need to implement functions now