Recoded TPCommand.java