player_set_history 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/player_set_history/climanager.rb +6 -6
- data/lib/player_set_history/importer.rb +5 -1
- data/lib/player_set_history/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: afda949e3b7a42fec82c244624650f783266fb2b1cf14e657b97dc69d037ba76
|
|
4
|
+
data.tar.gz: c19a02281dd2e802014761580ebbe9958433ed66f15040ff41dafcddd5591c03
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 02e910243d2c6605fb9dbb0e8ef691ae69454c4cb0408f0adbe4abeb9013a89da5149e666eb33b0b4e71abdfc29f7a395f493bfdcd8bc03a333b7d81de12b619
|
|
7
|
+
data.tar.gz: c6a240c0ef151b29dceb6f98382191d81d3e11a27e3f722819315d899097ca8f1eeff224b0205ce7a1408648cabfe027a45c681fd5e5d180ccf81fa8b0a17d86
|
data/Gemfile.lock
CHANGED
|
@@ -25,7 +25,7 @@ class PlayerSetHistory::CLIManager
|
|
|
25
25
|
end
|
|
26
26
|
|
|
27
27
|
game_id = get_game_id(input)
|
|
28
|
-
|
|
28
|
+
system("clear")
|
|
29
29
|
|
|
30
30
|
input = ""
|
|
31
31
|
puts "Please enter the players slug: \n\n"
|
|
@@ -54,7 +54,7 @@ class PlayerSetHistory::CLIManager
|
|
|
54
54
|
input = gets.chomp
|
|
55
55
|
end
|
|
56
56
|
|
|
57
|
-
|
|
57
|
+
system("clear")
|
|
58
58
|
puts "Loading..."
|
|
59
59
|
|
|
60
60
|
if input == "1"
|
|
@@ -71,14 +71,14 @@ class PlayerSetHistory::CLIManager
|
|
|
71
71
|
elsif input == "2"
|
|
72
72
|
input =""
|
|
73
73
|
importer.import_sets_from_sgg(player.slug, player.player_id)
|
|
74
|
-
|
|
74
|
+
system("clear")
|
|
75
75
|
puts "Enter the opponent's tag: "
|
|
76
76
|
|
|
77
77
|
until input != "" do
|
|
78
78
|
input = gets.chomp
|
|
79
79
|
end
|
|
80
80
|
|
|
81
|
-
|
|
81
|
+
system("clear")
|
|
82
82
|
puts "Loading..."
|
|
83
83
|
|
|
84
84
|
sets = player.get_all_sets_vs_player(input)
|
|
@@ -96,7 +96,7 @@ class PlayerSetHistory::CLIManager
|
|
|
96
96
|
|
|
97
97
|
elsif input == "3"
|
|
98
98
|
input = ""
|
|
99
|
-
|
|
99
|
+
system("clear")
|
|
100
100
|
puts "Please enter the players slug: \n\n"
|
|
101
101
|
puts "*To find the player slug, go to their smash.gg profile. You can pull it from the page itself or the url*: \n\nSample: Smash.gg/user/[slug]"
|
|
102
102
|
|
|
@@ -133,7 +133,7 @@ class PlayerSetHistory::CLIManager
|
|
|
133
133
|
end
|
|
134
134
|
|
|
135
135
|
def display_player_profile (player)
|
|
136
|
-
|
|
136
|
+
system("clear")
|
|
137
137
|
puts "----------------------"
|
|
138
138
|
puts "| Player Profile |"
|
|
139
139
|
puts "----------------------"
|
|
@@ -90,6 +90,10 @@ class PlayerSetHistory::Importer
|
|
|
90
90
|
)
|
|
91
91
|
|
|
92
92
|
event_hash = JSON.parse(result.response.body)["data"]["user"]
|
|
93
|
-
|
|
93
|
+
if event_hash["events"]["nodes"] == nil
|
|
94
|
+
puts "This player does not play this game"
|
|
95
|
+
else
|
|
96
|
+
PlayerSetHistory::Set.create_sets_from_player(event_hash, self)
|
|
97
|
+
end
|
|
94
98
|
end
|
|
95
99
|
end
|