awesome_game_randomizer 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cc530982d1efa380d28052a661b3536f4fbf46b2f74b6f24198a3f8a29d3f29c
4
- data.tar.gz: 1c1d5faf2e64497f225846d95ea6476be57a068e86fc6ab00cf9b2f125b0fb7b
3
+ metadata.gz: 489c2e1b70a2b13d49ccbaa6085ff674088d20512e7a934eb86bdfdff5bc4719
4
+ data.tar.gz: 99984e45cff48dc9d62490919495d5e1ac0bcbb49b354fde67f103a091ec4921
5
5
  SHA512:
6
- metadata.gz: 0bc12d11a52557d9f41c88d54615bac698ff788c82ad10694ee605bd015cfbfae49c077db3d2bc03b5b22214344b0a05c17822837b93d2ecfa17f013932b3772
7
- data.tar.gz: 5afbecd2fbd8672ef0b586be079ca90b81e1d84ed06598ae728faf6c65e1e678e7384f423b912ba4911bc10d5145241ff9c96d66d91d758ac531c97ab17e1c98
6
+ metadata.gz: 985c5c65afac018aa0dcb1d7cc0522a7f8a97a7bc3fff39c0b00dedb45e2b4c6befdc88a6f020f14e8a39b1c2f8aafeb527a26cf4b616a72b9e4ac3d8c4543db
7
+ data.tar.gz: 9f81ca1841198b066aea9f4fd7a6aea91daab59277bb83436ffaaff4673da3e80426be25d3398ff4de23b8c2b72f9dd41ccd369b16b850733acccd1ee5fa645b
data/README.md CHANGED
@@ -1,37 +1,27 @@
1
- # AwesomeGameRandomizer
2
-
3
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/awesome_game_randomizer`. To experiment with that code, run `bin/console` for an interactive prompt.
4
-
5
- TODO: Delete this and the text above, and describe your gem
6
-
7
- ## Installation
8
-
9
- Install the gem and add to the application's Gemfile by executing:
10
-
11
- $ bundle add awesome_game_randomizer
12
-
13
- If bundler is not being used to manage dependencies, install the gem by executing:
14
-
15
- $ gem install awesome_game_randomizer
16
-
17
- ## Usage
18
-
19
- TODO: Write usage instructions here
20
-
21
- ## Development
22
-
23
- After checking out the repo, run `bin/setup` to install dependencies. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
24
-
25
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
26
-
27
- ## Contributing
28
-
29
- Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/awesome_game_randomizer. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/[USERNAME]/awesome_game_randomizer/blob/master/CODE_OF_CONDUCT.md).
30
-
31
- ## License
32
-
33
- The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
34
-
35
- ## Code of Conduct
36
-
37
- Everyone interacting in the AwesomeGameRandomizer project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/awesome_game_randomizer/blob/master/CODE_OF_CONDUCT.md).
1
+ # <b>AwesomeGameRandomizer</b>
2
+
3
+ ##### Install awesome_game_randomizer gem
4
+ ````
5
+ gem install awesome_game_randomizer
6
+ ````
7
+ ##### To use Gem:
8
+ ````
9
+ require 'awesome_game_randomizer'
10
+ ````
11
+ ##### Flip a coin for heads or tails
12
+ ````
13
+ AwesomeGameRandomizer::Coin.flip
14
+ ````
15
+ ##### Draws a random card from a 52 card deck
16
+ ````
17
+ AwesomeGameRandomizer::PlayingCard.draw
18
+ ````
19
+ ##### Number of 6 sided dice to roll
20
+ ````
21
+ AwesomeGameRandomizer::Dice.roll(20)
22
+ ````
23
+ ##### First number is the number of selected numbers
24
+ ##### Second number is the range 1 to your number
25
+ ````
26
+ AwesomeGameRandomizer::Dice.roll(20)
27
+ ````
@@ -1,18 +1,19 @@
1
1
  module AwesomeGameRandomizer
2
2
  class Lotto
3
- def self.pick(count, nums)
4
- lotto_nums = []
3
+ def self.pick()
4
+ n = []
5
5
  i = 0
6
- if count <= nums
7
- while i < count
8
- pick = rand(1..nums)
9
- unless lotto_nums.include?(pick)
10
- lotto_nums << pick
6
+ if 7 <= 50
7
+ while i < 7
8
+ pick = rand(1..50)
9
+ unless n.include?(pick)
10
+ n << pick
11
11
  i += 1
12
12
  end
13
13
  end
14
14
  end
15
- puts "Error: not enough numbers"
15
+ puts "#{n[0]}, #{n[1]}, #{n[2]}, #{n[3]}, #{n[4]}, #{n[5]}, [#{n[6]}]"
16
16
  end
17
+ self.pick
17
18
  end
18
19
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module AwesomeGameRandomizer
4
- VERSION = "0.1.1"
4
+ VERSION = "0.1.2"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: awesome_game_randomizer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mark Mckinney
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-07-13 00:00:00.000000000 Z
11
+ date: 2022-07-14 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Write a longer description or delete this line.
14
14
  email: