work on state transitions