Implemented changing of State