99_game 4.0.3 → 4.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/lib/hand.rb +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
ZmRkZjhmMjg4NDYxN2Q4ZTFhOWNlNDA4N2JjNDM3YTQ2NDVkYzk0NQ==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
NDUxZGJlOTA0YmZkNTE5MjAwNDg0MWI0ZDc4Y2QyOWIyNGU5OGIyZA==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MzJkZTU0ZDJjN2JjNjRmODQ3OWIxMjhkNjFiMWIwNDVhNGU3MTdlNjIzZDcw
|
10
|
+
MGVmZjNjNDRkZjg5ZWJjYjdjMmE1YzI3ZjIwNTQzYTQ1OTczYzg5NjkzMjA1
|
11
|
+
MTQ0ZjljY2RmYmUzOGQxYzUwMmMwMzg2YWY5ZjhkNDBiNGIwNjU=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NGUzN2Y3YTkzMTBjYmZmZjJjY2I5ZWE4NmY2Y2JiMjg5ZTFlNWMyMWU5MWRl
|
14
|
+
OTE0ODA4YTUwOGUxOWY3YjViNWI4YjhlYzI2NTNmNDEwZDljNTA2YzY4YTQz
|
15
|
+
OGNkNGFlNGY0ODMwZDgxYTRiMWYwNjA5MTg3Y2YyMTg3MTdhMWM=
|
data/lib/hand.rb
CHANGED
@@ -50,13 +50,13 @@ class Hand # Creates an object that holds and can play cards. Interacts with Dec
|
|
50
50
|
when "King"
|
51
51
|
if (@cards - [card]).any? {|card| [4, 9, "Jack", "Queen", "King", "Joker"].include? card.num} || rand < 0.1
|
52
52
|
99
|
53
|
-
else -
|
53
|
+
else -99
|
54
54
|
end
|
55
55
|
when "Joker" then 0
|
56
56
|
else
|
57
57
|
$value + card.value
|
58
58
|
end
|
59
|
-
test_value = -
|
59
|
+
test_value = -100 if test_value > 99
|
60
60
|
outcomes << test_value
|
61
61
|
end
|
62
62
|
return outcomes
|