Command class, detecting commands