Method: TFClient::CommandParser#parse

Defined in:
lib/textflight-client/command_parser.rb

#parseObject



29
30
31
32
33
34
35
36
37
38
39
40
# File 'lib/textflight-client/command_parser.rb', line 29

def parse
  if @command == "quit" || @command == "exit"
    return "exit"
  end

  direction = DIRECTION_MAP[@command.to_sym]
  if direction
    "jump #{direction}"
  else
    @command
  end
end