mousevc_rock_paper_scissors 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +12 -0
- data/.rspec +2 -0
- data/.travis.yml +4 -0
- data/CODE_OF_CONDUCT.md +13 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +121 -0
- data/Rakefile +6 -0
- data/bin/console +16 -0
- data/bin/setup +7 -0
- data/lib/mousevc_rock_paper_scissors.rb +20 -0
- data/lib/mousevc_rock_paper_scissors/game_controller.rb +83 -0
- data/lib/mousevc_rock_paper_scissors/game_model.rb +89 -0
- data/lib/mousevc_rock_paper_scissors/game_validation.rb +17 -0
- data/lib/mousevc_rock_paper_scissors/hand.rb +87 -0
- data/lib/mousevc_rock_paper_scissors/version.rb +7 -0
- data/lib/views/form.txt.erb +1 -0
- data/lib/views/game.txt.erb +6 -0
- data/lib/views/menu.txt.erb +3 -0
- data/lib/views/over.txt.erb +4 -0
- data/lib/views/paper.txt.erb +3 -0
- data/lib/views/play.txt.erb +7 -0
- data/lib/views/rock.txt.erb +3 -0
- data/lib/views/scissors.txt.erb +3 -0
- data/lib/views/tie.txt.erb +8 -0
- data/lib/views/winner.txt.erb +8 -0
- data/mousevc_rock_paper_scissors.gemspec +35 -0
- metadata +130 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 0b8c935f672ff266419173273b3da7f275774c09
|
4
|
+
data.tar.gz: bd9ad55afab4a6eb0efff18ba11002040739c25a
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: a22947c24332225599bc7e2f08474b4936e29197599cd1f944e7c12e953b8eec30ee26de6003d2a22c37e782ce8d7d2a7f575db23ae1017731331c6421e50c8e
|
7
|
+
data.tar.gz: f1f24e07490912b61226e88d7e158966f3ce7554edfce05edbc44ef48eba54987faf21b54ff2a220ea7857c3a449afe17fc0dff0a51f6cead2cf128412293827
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
# Contributor Code of Conduct
|
2
|
+
|
3
|
+
As contributors and maintainers of this project, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.
|
4
|
+
|
5
|
+
We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, ethnicity, age, or religion.
|
6
|
+
|
7
|
+
Examples of unacceptable behavior by participants include the use of sexual language or imagery, derogatory comments or personal attacks, trolling, public or private harassment, insults, or other unprofessional conduct.
|
8
|
+
|
9
|
+
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. Project maintainers who do not follow the Code of Conduct may be removed from the project team.
|
10
|
+
|
11
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an issue or contacting one or more of the project maintainers.
|
12
|
+
|
13
|
+
This Code of Conduct is adapted from the [Contributor Covenant](http://contributor-covenant.org), version 1.0.0, available at [http://contributor-covenant.org/version/1/0/0/](http://contributor-covenant.org/version/1/0/0/)
|
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2015 Chris Scavello
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,121 @@
|
|
1
|
+
# MousevcRockPaperScissors
|
2
|
+
|
3
|
+
This is an example command line game of "Rock, Paper, Scissors" using the [Mousevc framework][mousevc].
|
4
|
+
|
5
|
+
## Installation
|
6
|
+
|
7
|
+
Add this line to your application's Gemfile:
|
8
|
+
|
9
|
+
```ruby
|
10
|
+
gem 'mousevc_rock_paper_scissors'
|
11
|
+
```
|
12
|
+
|
13
|
+
And then execute:
|
14
|
+
|
15
|
+
```
|
16
|
+
$ bundle
|
17
|
+
```
|
18
|
+
|
19
|
+
Or install it yourself as:
|
20
|
+
|
21
|
+
```
|
22
|
+
$ gem install mousevc_rock_paper_scissors
|
23
|
+
```
|
24
|
+
|
25
|
+
## Usage
|
26
|
+
|
27
|
+
1. Since this is a command line game, pop into IRB and load the gem.
|
28
|
+
|
29
|
+
```
|
30
|
+
$ irb
|
31
|
+
```
|
32
|
+
|
33
|
+
```ruby
|
34
|
+
require 'mousevc_rock_paper_scissors'
|
35
|
+
```
|
36
|
+
|
37
|
+
1. Create a new game and run it!
|
38
|
+
|
39
|
+
```ruby
|
40
|
+
game = MousevcRockPaperScissors::Game.new.run
|
41
|
+
```
|
42
|
+
|
43
|
+
1. Choose between 1 or 2 player
|
44
|
+
|
45
|
+
```
|
46
|
+
Rock Paper Scissors
|
47
|
+
-------------------
|
48
|
+
Welcome to Rock Paper Scissors
|
49
|
+
Type 'q', 'quit', or 'exit' to quit
|
50
|
+
Type 'r', or 'reset' to reset
|
51
|
+
|
52
|
+
|
53
|
+
Please select 1 or 2 players
|
54
|
+
|
55
|
+
> 1
|
56
|
+
```
|
57
|
+
|
58
|
+
1. Choose a hand, I like paper!
|
59
|
+
|
60
|
+
```
|
61
|
+
Rock Paper Scissors
|
62
|
+
-------------------
|
63
|
+
Welcome to Rock Paper Scissors
|
64
|
+
Type 'q', 'quit', or 'exit' to quit
|
65
|
+
Type 'r', or 'reset' to reset
|
66
|
+
|
67
|
+
|
68
|
+
Player 1 select a hand:
|
69
|
+
|
70
|
+
1. Rock
|
71
|
+
2. Paper
|
72
|
+
3. Scissors
|
73
|
+
|
74
|
+
> 2
|
75
|
+
```
|
76
|
+
|
77
|
+
1. Rock, Paper, Scissors, SHOOT! Paper wins!
|
78
|
+
|
79
|
+
```
|
80
|
+
Rock Paper Scissors
|
81
|
+
-------------------
|
82
|
+
Welcome to Rock Paper Scissors
|
83
|
+
Type 'q', 'quit', or 'exit' to quit
|
84
|
+
Type 'r', or 'reset' to reset
|
85
|
+
|
86
|
+
|
87
|
+
Player 1 Wins!
|
88
|
+
|
89
|
+
|--\
|
90
|
+
| |
|
91
|
+
|___|
|
92
|
+
|
93
|
+
-- beats --
|
94
|
+
|
95
|
+
/-/\
|
96
|
+
| , '|
|
97
|
+
\_/-/
|
98
|
+
|
99
|
+
Game Over!
|
100
|
+
|
101
|
+
Play again? Press [Enter]
|
102
|
+
|
103
|
+
>
|
104
|
+
```
|
105
|
+
|
106
|
+
## Development
|
107
|
+
|
108
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
109
|
+
|
110
|
+
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 tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
111
|
+
|
112
|
+
## Contributing
|
113
|
+
|
114
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/BideoWego/mousevc_rock_paper_scissors. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](contributor-covenant.org) code of conduct.
|
115
|
+
|
116
|
+
|
117
|
+
## License
|
118
|
+
|
119
|
+
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
120
|
+
|
121
|
+
[mousevc]: https://rubygems.org/gems/mousevc/versions/0.0.4
|
data/Rakefile
ADDED
data/bin/console
ADDED
@@ -0,0 +1,16 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require "bundler/setup"
|
4
|
+
require "mousevc_rock_paper_scissors"
|
5
|
+
|
6
|
+
g = MousevcRockPaperScissors::Game.new.run
|
7
|
+
|
8
|
+
# You can add fixtures and/or initialization code here to make experimenting
|
9
|
+
# with your gem easier. You can also use a different console, if you like.
|
10
|
+
|
11
|
+
# (If you use this, don't forget to add pry to your Gemfile!)
|
12
|
+
# require "pry"
|
13
|
+
# Pry.start
|
14
|
+
|
15
|
+
require "irb"
|
16
|
+
IRB.start
|
data/bin/setup
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
require 'mousevc'
|
2
|
+
|
3
|
+
require_relative 'mousevc_rock_paper_scissors/version.rb'
|
4
|
+
require_relative 'mousevc_rock_paper_scissors/game_controller.rb'
|
5
|
+
require_relative 'mousevc_rock_paper_scissors/game_model.rb'
|
6
|
+
|
7
|
+
module MousevcRockPaperScissors
|
8
|
+
class Game < Mousevc::App
|
9
|
+
def initialize
|
10
|
+
super(
|
11
|
+
:controller => 'GameController',
|
12
|
+
:model => 'GameModel',
|
13
|
+
:views => 'lib/views',
|
14
|
+
:action => :menu,
|
15
|
+
:looping => true,
|
16
|
+
:system_clear => true
|
17
|
+
)
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
@@ -0,0 +1,83 @@
|
|
1
|
+
class GameController < Mousevc::Controller
|
2
|
+
def menu
|
3
|
+
@view.render('game')
|
4
|
+
@view.render('menu')
|
5
|
+
@view.render('form')
|
6
|
+
@router.action = :select_players
|
7
|
+
end
|
8
|
+
|
9
|
+
def play
|
10
|
+
@view.render('game')
|
11
|
+
@view.render('play',
|
12
|
+
:turn => @model.turn
|
13
|
+
)
|
14
|
+
@view.render('form')
|
15
|
+
@router.action = :one_player unless @model.two_player?
|
16
|
+
@router.action = :two_player if @model.two_player?
|
17
|
+
end
|
18
|
+
|
19
|
+
def over
|
20
|
+
@view.render('game')
|
21
|
+
if @model.tie?
|
22
|
+
@view.render('tie',
|
23
|
+
:hand_player_one => @view.render(
|
24
|
+
@model.player_one,
|
25
|
+
false
|
26
|
+
),
|
27
|
+
:hand_player_two => @view.render(
|
28
|
+
@model.player_two,
|
29
|
+
false
|
30
|
+
)
|
31
|
+
)
|
32
|
+
else
|
33
|
+
shoot = @model.shoot
|
34
|
+
@view.render('winner',
|
35
|
+
:winner => shoot[:winner],
|
36
|
+
:winning_hand => @view.render(
|
37
|
+
shoot[:winning_hand],
|
38
|
+
false
|
39
|
+
),
|
40
|
+
:losing_hand => @view.render(
|
41
|
+
shoot[:losing_hand],
|
42
|
+
false
|
43
|
+
)
|
44
|
+
)
|
45
|
+
end
|
46
|
+
@view.render('over')
|
47
|
+
@view.render('form')
|
48
|
+
@router.action = :menu
|
49
|
+
@model.clear
|
50
|
+
end
|
51
|
+
|
52
|
+
def select_players
|
53
|
+
@model.num_players = Mousevc::Input.data
|
54
|
+
if @model.num_players
|
55
|
+
@router.action = :play
|
56
|
+
else
|
57
|
+
Mousevc::Input.notice = @model.validation.error
|
58
|
+
@router.action = :menu
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
def one_player
|
63
|
+
@model.player_one = Mousevc::Input.data
|
64
|
+
if @model.player_one
|
65
|
+
@model.player_two = ['1', '2', '3'].shuffle.first
|
66
|
+
@router.action = :over
|
67
|
+
else
|
68
|
+
Mousevc::Input.notice = @model.validation.error
|
69
|
+
@router.action = :play
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
def two_player
|
74
|
+
current_player = @model.current_player
|
75
|
+
@model.current_player = Mousevc::Input.data
|
76
|
+
if @model.send(current_player)
|
77
|
+
@router.action = @model.shoot_ready? ? :over : :play
|
78
|
+
else
|
79
|
+
Mousevc::Input.notice = @model.validation.error
|
80
|
+
@router.action = :play
|
81
|
+
end
|
82
|
+
end
|
83
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
require_relative 'game_validation.rb'
|
2
|
+
require_relative 'hand.rb'
|
3
|
+
|
4
|
+
class GameModel < Mousevc::Model
|
5
|
+
attr_accessor :num_players, :player_one, :player_two
|
6
|
+
|
7
|
+
def initialize
|
8
|
+
super(:validation => GameValidation.new)
|
9
|
+
end
|
10
|
+
|
11
|
+
def clear
|
12
|
+
@num_players = nil
|
13
|
+
@player_one = nil
|
14
|
+
@player_two = nil
|
15
|
+
end
|
16
|
+
|
17
|
+
def current_player
|
18
|
+
player = :player_one if turn == '1'
|
19
|
+
player = :player_two if turn == '2'
|
20
|
+
player
|
21
|
+
end
|
22
|
+
|
23
|
+
def current_player=(value)
|
24
|
+
player = nil
|
25
|
+
if @validation.valid_hand?(value)
|
26
|
+
player = @player_two = select_hand(value) if turn == '2'
|
27
|
+
player = @player_one = select_hand(value) if turn == '1'
|
28
|
+
end
|
29
|
+
player
|
30
|
+
end
|
31
|
+
|
32
|
+
def num_players=(value)
|
33
|
+
@num_players = value if @validation.valid_num_players?(value)
|
34
|
+
end
|
35
|
+
|
36
|
+
def player_one=(value)
|
37
|
+
@player_one = select_hand(value) if @validation.valid_hand?(value)
|
38
|
+
end
|
39
|
+
|
40
|
+
def player_two=(value)
|
41
|
+
@player_two = select_hand(value) if @validation.valid_hand?(value)
|
42
|
+
end
|
43
|
+
|
44
|
+
def turn
|
45
|
+
return '2' if two_player? && @player_one
|
46
|
+
return '1'
|
47
|
+
end
|
48
|
+
|
49
|
+
def shoot
|
50
|
+
if @player_one.beats?(@player_two)
|
51
|
+
winner = '1'
|
52
|
+
loser = '2'
|
53
|
+
winning_hand = @player_one.to_s
|
54
|
+
losing_hand = @player_two.to_s
|
55
|
+
else
|
56
|
+
winner = '2'
|
57
|
+
loser = '1'
|
58
|
+
winning_hand = @player_two.to_s
|
59
|
+
losing_hand = @player_one.to_s
|
60
|
+
end
|
61
|
+
{
|
62
|
+
:winner => winner,
|
63
|
+
:loser => loser,
|
64
|
+
:winning_hand => winning_hand,
|
65
|
+
:losing_hand => losing_hand
|
66
|
+
}
|
67
|
+
end
|
68
|
+
|
69
|
+
def tie?
|
70
|
+
@player_one.ties?(@player_two)
|
71
|
+
end
|
72
|
+
|
73
|
+
def two_player?
|
74
|
+
@num_players == '2'
|
75
|
+
end
|
76
|
+
|
77
|
+
def shoot_ready?
|
78
|
+
@player_one && @player_two
|
79
|
+
end
|
80
|
+
|
81
|
+
private
|
82
|
+
def select_hand(value)
|
83
|
+
[
|
84
|
+
Rock.new,
|
85
|
+
Paper.new,
|
86
|
+
Scissors.new
|
87
|
+
][value.to_i - 1]
|
88
|
+
end
|
89
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
class GameValidation < Mousevc::Validation
|
2
|
+
def valid_num_players?(n)
|
3
|
+
valid_num_players = ['1', '2'].include?(n)
|
4
|
+
unless valid_num_players
|
5
|
+
@error = "Invalid number of players: #{n.to_i.to_s}"
|
6
|
+
end
|
7
|
+
valid_num_players
|
8
|
+
end
|
9
|
+
|
10
|
+
def valid_hand?(n)
|
11
|
+
valid_hand = ['1', '2', '3'].include?(n)
|
12
|
+
unless valid_hand
|
13
|
+
@error = "Invalid hand: #{n.to_i.to_s}"
|
14
|
+
end
|
15
|
+
valid_hand
|
16
|
+
end
|
17
|
+
end
|
@@ -0,0 +1,87 @@
|
|
1
|
+
class Hand
|
2
|
+
def compare(hand)
|
3
|
+
end
|
4
|
+
|
5
|
+
def >(other)
|
6
|
+
beats?(other)
|
7
|
+
end
|
8
|
+
|
9
|
+
def <(other)
|
10
|
+
! beats?(other)
|
11
|
+
end
|
12
|
+
|
13
|
+
def >=(other)
|
14
|
+
beats?(other) || ties?(other)
|
15
|
+
end
|
16
|
+
|
17
|
+
def <=(other)
|
18
|
+
! beats?(other) || ties?(other)
|
19
|
+
end
|
20
|
+
|
21
|
+
def ==(other)
|
22
|
+
ties?(other)
|
23
|
+
end
|
24
|
+
|
25
|
+
def <=>(other)
|
26
|
+
self.compare(other) <=> other.compare(self)
|
27
|
+
end
|
28
|
+
|
29
|
+
def ties?(hand)
|
30
|
+
(self <=> hand) == 0
|
31
|
+
end
|
32
|
+
|
33
|
+
def beats?(hand)
|
34
|
+
(self <=> hand) == 1
|
35
|
+
end
|
36
|
+
end
|
37
|
+
|
38
|
+
class Rock < Hand
|
39
|
+
def compare(hand)
|
40
|
+
case hand
|
41
|
+
when Rock
|
42
|
+
return 0
|
43
|
+
when Paper
|
44
|
+
return -1
|
45
|
+
when Scissors
|
46
|
+
return 1
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
def to_s
|
51
|
+
'rock'
|
52
|
+
end
|
53
|
+
end
|
54
|
+
|
55
|
+
class Paper < Hand
|
56
|
+
def compare(hand)
|
57
|
+
case hand
|
58
|
+
when Rock
|
59
|
+
return 1
|
60
|
+
when Paper
|
61
|
+
return 0
|
62
|
+
when Scissors
|
63
|
+
return -1
|
64
|
+
end
|
65
|
+
end
|
66
|
+
|
67
|
+
def to_s
|
68
|
+
'paper'
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
class Scissors < Hand
|
73
|
+
def compare(hand)
|
74
|
+
case hand
|
75
|
+
when Rock
|
76
|
+
return -1
|
77
|
+
when Paper
|
78
|
+
return 1
|
79
|
+
when Scissors
|
80
|
+
return 0
|
81
|
+
end
|
82
|
+
end
|
83
|
+
|
84
|
+
def to_s
|
85
|
+
'scissors'
|
86
|
+
end
|
87
|
+
end
|
@@ -0,0 +1 @@
|
|
1
|
+
<% Input.prompt %>
|
@@ -0,0 +1,35 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'mousevc_rock_paper_scissors/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "mousevc_rock_paper_scissors"
|
8
|
+
spec.version = MousevcRockPaperScissors::VERSION
|
9
|
+
spec.authors = ["Chris Scavello"]
|
10
|
+
spec.email = ["bideowego@gmail.com"]
|
11
|
+
|
12
|
+
spec.summary = %q{An example command line version of "Rock, Paper, Scissors" using the Mousevc framework: https://rubygems.org/gems/mousevc}
|
13
|
+
# spec.description = %q{TODO: Write a longer description or delete this line.}
|
14
|
+
spec.homepage = "http://bideowego.com/mousevc"
|
15
|
+
spec.license = "MIT"
|
16
|
+
|
17
|
+
# Prevent pushing this gem to RubyGems.org by setting 'allowed_push_host', or
|
18
|
+
# delete this section to allow pushing this gem to any host.
|
19
|
+
if spec.respond_to?(:metadata)
|
20
|
+
spec.metadata['allowed_push_host'] = "https://rubygems.org"
|
21
|
+
else
|
22
|
+
raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
|
23
|
+
end
|
24
|
+
|
25
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
26
|
+
spec.bindir = "exe"
|
27
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
28
|
+
spec.require_paths = ["lib"]
|
29
|
+
|
30
|
+
spec.add_development_dependency "bundler", "~> 1.10"
|
31
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
32
|
+
spec.add_development_dependency "rspec"
|
33
|
+
|
34
|
+
spec.add_dependency "mousevc", '0.0.4'
|
35
|
+
end
|
metadata
ADDED
@@ -0,0 +1,130 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: mousevc_rock_paper_scissors
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Chris Scavello
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2015-08-24 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.10'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.10'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '10.0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '10.0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rspec
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: mousevc
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - '='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 0.0.4
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - '='
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: 0.0.4
|
69
|
+
description:
|
70
|
+
email:
|
71
|
+
- bideowego@gmail.com
|
72
|
+
executables: []
|
73
|
+
extensions: []
|
74
|
+
extra_rdoc_files: []
|
75
|
+
files:
|
76
|
+
- ".gitignore"
|
77
|
+
- ".rspec"
|
78
|
+
- ".travis.yml"
|
79
|
+
- CODE_OF_CONDUCT.md
|
80
|
+
- Gemfile
|
81
|
+
- LICENSE.txt
|
82
|
+
- README.md
|
83
|
+
- Rakefile
|
84
|
+
- bin/console
|
85
|
+
- bin/setup
|
86
|
+
- lib/mousevc_rock_paper_scissors.rb
|
87
|
+
- lib/mousevc_rock_paper_scissors/game_controller.rb
|
88
|
+
- lib/mousevc_rock_paper_scissors/game_model.rb
|
89
|
+
- lib/mousevc_rock_paper_scissors/game_validation.rb
|
90
|
+
- lib/mousevc_rock_paper_scissors/hand.rb
|
91
|
+
- lib/mousevc_rock_paper_scissors/version.rb
|
92
|
+
- lib/views/form.txt.erb
|
93
|
+
- lib/views/game.txt.erb
|
94
|
+
- lib/views/menu.txt.erb
|
95
|
+
- lib/views/over.txt.erb
|
96
|
+
- lib/views/paper.txt.erb
|
97
|
+
- lib/views/play.txt.erb
|
98
|
+
- lib/views/rock.txt.erb
|
99
|
+
- lib/views/scissors.txt.erb
|
100
|
+
- lib/views/tie.txt.erb
|
101
|
+
- lib/views/winner.txt.erb
|
102
|
+
- mousevc_rock_paper_scissors.gemspec
|
103
|
+
homepage: http://bideowego.com/mousevc
|
104
|
+
licenses:
|
105
|
+
- MIT
|
106
|
+
metadata:
|
107
|
+
allowed_push_host: https://rubygems.org
|
108
|
+
post_install_message:
|
109
|
+
rdoc_options: []
|
110
|
+
require_paths:
|
111
|
+
- lib
|
112
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
113
|
+
requirements:
|
114
|
+
- - ">="
|
115
|
+
- !ruby/object:Gem::Version
|
116
|
+
version: '0'
|
117
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
118
|
+
requirements:
|
119
|
+
- - ">="
|
120
|
+
- !ruby/object:Gem::Version
|
121
|
+
version: '0'
|
122
|
+
requirements: []
|
123
|
+
rubyforge_project:
|
124
|
+
rubygems_version: 2.4.6
|
125
|
+
signing_key:
|
126
|
+
specification_version: 4
|
127
|
+
summary: 'An example command line version of "Rock, Paper, Scissors" using the Mousevc
|
128
|
+
framework: https://rubygems.org/gems/mousevc'
|
129
|
+
test_files: []
|
130
|
+
has_rdoc:
|