Ripoff of state machine from sevabot examples