added command logic, not complete