finished state machine friend section