Class: Smite::MatchSummary
Instance Attribute Summary
Attributes inherited from Object
#data
Instance Method Summary
collapse
Methods inherited from Object
#attributes, #method_missing
Constructor Details
3
4
5
6
7
8
|
# File 'lib/smite/match_summary.rb', line 3
def initialize(data)
super
@data = DataTransform.transform_gods(@data)
@data = DataTransform.transform_items(@data)
@data = DataTransform.transform_match_summary(@data)
end
|
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
in the class Smite::Object
Instance Method Details
23
24
25
|
# File 'lib/smite/match_summary.rb', line 23
def id
match
end
|
27
28
29
|
# File 'lib/smite/match_summary.rb', line 27
def inspect
"#<Smite::MatchSummary #{match} '#{queue}' (#{win_status})>"
end
|
#loss? ⇒ Boolean
19
20
21
|
# File 'lib/smite/match_summary.rb', line 19
def loss?
!win?
end
|
#to_full_match ⇒ Object
Also known as:
full_match
10
11
12
|
# File 'lib/smite/match_summary.rb', line 10
def to_full_match
Smite::Game.match(match)
end
|
#win? ⇒ Boolean
15
16
17
|
# File 'lib/smite/match_summary.rb', line 15
def win?
win_status == 'Win'
end
|