Class: Lyne::Parser::Info

Inherits:
Home show all
Defined in:
lib/lyne/parser/home.rb

Instance Method Summary collapse

Methods inherited from Home

#initialize

Methods inherited from Base

#initialize, #nbsp

Constructor Details

This class inherits a constructor from Lyne::Parser::Home

Instance Method Details

#genki_chargeObject



39
40
41
# File 'lib/lyne/parser/home.rb', line 39

def genki_charge
  get_parse_data(index: 27)
end

#goldObject



35
36
37
# File 'lib/lyne/parser/home.rb', line 35

def gold
  get_parse_data(index: 23)
end

#idObject



27
28
29
# File 'lib/lyne/parser/home.rb', line 27

def id
  get_parse_data(index: 3)
end

#jobObject



15
16
17
# File 'lib/lyne/parser/home.rb', line 15

def job
  get_parse_data(index: 11)
end

#levelObject



23
24
25
# File 'lib/lyne/parser/home.rb', line 23

def level
  get_parse_data(index: 15)
end

#nameObject



11
12
13
# File 'lib/lyne/parser/home.rb', line 11

def name
  @result.xpath("//h2[@id='myCharacterName']").text.gsub(/\[|\]/, '')
end

#next_levelObject



31
32
33
# File 'lib/lyne/parser/home.rb', line 31

def next_level
  get_parse_data(index: 19)
end

#tribeObject



19
20
21
# File 'lib/lyne/parser/home.rb', line 19

def tribe
  get_parse_data(index: 7, regexp: /:|#{nbsp}|男|女/)
end