Comment Text + Simple State Machine

added simple state machine & comment text switching.