physh_roller 0.0.1 → 1.0.1
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/README +55 -1
- data/lib/physh_roller/dice_roll.rb +27 -10
- data/lib/physh_roller.rb +3 -0
- metadata +16 -62
- data/doc/Object.html +0 -204
- data/doc/Output.html +0 -226
- data/doc/PhyshRoller/DiceRoll.html +0 -498
- data/doc/PhyshRoller/Die.html +0 -266
- data/doc/PhyshRoller.html +0 -140
- data/doc/created.rid +0 -14
- data/doc/doc/created_rid.html +0 -97
- data/doc/features/physh_roller/parse_dice_roll_string_feature.html +0 -117
- data/doc/features/physh_roller/roll_dice_feature.html +0 -119
- data/doc/features/physh_roller/roll_die_feature.html +0 -117
- data/doc/images/add.png +0 -0
- data/doc/images/arrow_up.png +0 -0
- data/doc/images/brick.png +0 -0
- data/doc/images/brick_link.png +0 -0
- data/doc/images/bug.png +0 -0
- data/doc/images/bullet_black.png +0 -0
- data/doc/images/bullet_toggle_minus.png +0 -0
- data/doc/images/bullet_toggle_plus.png +0 -0
- data/doc/images/date.png +0 -0
- data/doc/images/delete.png +0 -0
- data/doc/images/find.png +0 -0
- data/doc/images/loadingAnimation.gif +0 -0
- data/doc/images/macFFBgHack.png +0 -0
- data/doc/images/package.png +0 -0
- data/doc/images/page_green.png +0 -0
- data/doc/images/page_white_text.png +0 -0
- data/doc/images/page_white_width.png +0 -0
- data/doc/images/plugin.png +0 -0
- data/doc/images/ruby.png +0 -0
- data/doc/images/tag_blue.png +0 -0
- data/doc/images/tag_green.png +0 -0
- data/doc/images/transparent.png +0 -0
- data/doc/images/wrench.png +0 -0
- data/doc/images/wrench_orange.png +0 -0
- data/doc/images/zoom.png +0 -0
- data/doc/index.html +0 -94
- data/doc/js/darkfish.js +0 -155
- data/doc/js/jquery.js +0 -18
- data/doc/js/navigation.js +0 -142
- data/doc/js/search.js +0 -94
- data/doc/js/search_index.js +0 -1
- data/doc/js/searcher.js +0 -228
- data/doc/rdoc.css +0 -595
- data/doc/table_of_contents.html +0 -98
- data/features/physh_roller/parse_dice_roll_string.feature +0 -19
- data/features/physh_roller/roll_dice.feature +0 -22
- data/features/physh_roller/roll_die.feature +0 -19
- data/features/step_definitions/physh_roller/physh_roller_steps.rb +0 -79
- data/features/support/env.rb +0 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9657b33b99f914a4cf30e78a51c1f7de5da71483
|
4
|
+
data.tar.gz: 8f2f0ebf7e929cade84e7c48cbd20aa497b38945
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 853ca6638ef6436535a2384af558a01cf300b35450af660c3112cc69bca4850eec2d3e4fee4b1b7cbfdc76ac2df68e50f237ff1dea5f2e5ae36f76b6e540df26
|
7
|
+
data.tar.gz: c226a5dcf6bbc09837f49767ae4aa06596c409d4e1b1f590be4cb65d66015dd671e911057b01ac7e47dbc1e612fd33ff9a75c9364bf1af9e2beee84781f0df55
|
data/README
CHANGED
@@ -1 +1,55 @@
|
|
1
|
-
A simple dice rolling application.
|
1
|
+
A simple dice rolling application.
|
2
|
+
|
3
|
+
Usage
|
4
|
+
=====
|
5
|
+
|
6
|
+
Command Line
|
7
|
+
------------
|
8
|
+
|
9
|
+
If you've installed the gem, you can simply run:
|
10
|
+
|
11
|
+
dice <the_dice_string_i_want_to_roll>
|
12
|
+
|
13
|
+
Example dice strings are 4d6, 20d100-20, 14D2+6. Basically, anything that matches the regular expression /\A(\d+)?d(\d+)([\+-]\d*)?\z/i.
|
14
|
+
|
15
|
+
As A Module
|
16
|
+
-----------
|
17
|
+
|
18
|
+
You can require physh_roller in a Ruby application and then create dicerolls.
|
19
|
+
|
20
|
+
For example:
|
21
|
+
|
22
|
+
dice_roll = PhyshRoller::DiceRoll.new('2d10+30')
|
23
|
+
|
24
|
+
dice_roll.roll_dice
|
25
|
+
|
26
|
+
first_roll = dice_roll.results
|
27
|
+
|
28
|
+
dice_roll.roll_dice
|
29
|
+
|
30
|
+
second_roll = dice_roll.results
|
31
|
+
|
32
|
+
first_total = first_roll[:sum]
|
33
|
+
|
34
|
+
second_total = second_roll[:sum]
|
35
|
+
|
36
|
+
Documentation
|
37
|
+
=============
|
38
|
+
|
39
|
+
More documentation is available in RDoc format in the /doc folder.
|
40
|
+
|
41
|
+
Why Have You Done This Thing?
|
42
|
+
=============================
|
43
|
+
|
44
|
+
I play RPGs a lot. A lot of the tools I build relate to these games and most of them use dice rolls. I got fed up having to do stuff on the fly and decided to do the thing properly.
|
45
|
+
|
46
|
+
This is also my first real excursion in to really using BDD/TDD. I might have paid lip service to writing tests first, but the end goal was working code. This time I'm (hopefully) doing it right.
|
47
|
+
|
48
|
+
If you have the time, please take a look at the Cucumber and RSpec test suite and let me know where it can be improved. That goes for the rest of the code too. :)
|
49
|
+
|
50
|
+
Where Does It Go From Here
|
51
|
+
==========================
|
52
|
+
|
53
|
+
I fully intend to add functionality for exploding dice (reroll on maximum, or a threshold), successes on individual dice (as per Shadowrun or nWoD).
|
54
|
+
|
55
|
+
Again, if there are any other dice strangenesses you would like to see implemented, please do let me know.
|
@@ -1,10 +1,20 @@
|
|
1
1
|
module PhyshRoller
|
2
2
|
class DiceRoll
|
3
|
+
# Splits a dice roll string in to the :number_of_dice,
|
4
|
+
# :sides_on_dice and :roll_modifier capture groups.
|
3
5
|
DICE_ROLL_REGEXP = /\A(\d+)?d(\d+)([\+-]\d*)?\z/i
|
4
6
|
|
5
|
-
|
6
|
-
|
7
|
+
# The original dice roll string, downcased and validated.
|
8
|
+
attr_reader :dice_roll_string
|
9
|
+
|
10
|
+
attr_reader :sides_on_dice, :roll_modifier, :dice_array
|
7
11
|
|
12
|
+
# Accepts the initial :dice_roll_string and sets the default
|
13
|
+
# attributes.
|
14
|
+
#
|
15
|
+
# Can also take an :output attribute, which is currently only
|
16
|
+
# used for test doubles, but down the line may be used for other
|
17
|
+
# nefarious purposes.
|
8
18
|
def initialize(dice_roll_string, output=$stdout)
|
9
19
|
@output = output
|
10
20
|
@dice_roll_string = dice_roll_string.downcase.gsub(' ', '')
|
@@ -20,18 +30,13 @@ module PhyshRoller
|
|
20
30
|
!!(@dice_roll_string =~ DICE_ROLL_REGEXP)
|
21
31
|
end
|
22
32
|
|
23
|
-
def set_default_values
|
24
|
-
@number_of_dice, @sides_on_dice, @roll_modifier =
|
25
|
-
DICE_ROLL_REGEXP.match(@dice_roll_string).captures.map { |capture| capture.to_i }
|
26
|
-
@number_of_dice = 1 unless (@number_of_dice > 0)
|
27
|
-
@roll_modifier ||= 0
|
28
|
-
@dice_array = []
|
29
|
-
end
|
30
|
-
|
31
33
|
def roll_dice
|
32
34
|
@dice_array.each { |die| die.roll }
|
35
|
+
return self
|
33
36
|
end
|
34
37
|
|
38
|
+
# Creates the required instances of the Die class and adds
|
39
|
+
# them to the :dice_array
|
35
40
|
def add_dice_to_dice_array(number_of_dice, sides_on_dice)
|
36
41
|
number_of_dice.times do
|
37
42
|
die = Die.new(sides_on_dice)
|
@@ -58,5 +63,17 @@ module PhyshRoller
|
|
58
63
|
@output.puts "Dice rolls: #{results[:dice_rolls].join(',')}"
|
59
64
|
@output.puts "Total: #{results[:sum]}"
|
60
65
|
end
|
66
|
+
|
67
|
+
private
|
68
|
+
|
69
|
+
# Generates the default attrributes from the validated
|
70
|
+
# :dice_roll_string.
|
71
|
+
def set_default_values
|
72
|
+
@number_of_dice, @sides_on_dice, @roll_modifier =
|
73
|
+
DICE_ROLL_REGEXP.match(@dice_roll_string).captures.map { |capture| capture.to_i }
|
74
|
+
@number_of_dice = 1 unless (@number_of_dice > 0)
|
75
|
+
@roll_modifier ||= 0
|
76
|
+
@dice_array = []
|
77
|
+
end
|
61
78
|
end
|
62
79
|
end
|
data/lib/physh_roller.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: physh_roller
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kryptyk Fysh
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-03-
|
11
|
+
date: 2013-03-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -38,76 +38,30 @@ dependencies:
|
|
38
38
|
- - '>='
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
|
-
description: A
|
41
|
+
description: " A Ruby code dice rolling application that cna be used both as a\n
|
42
|
+
\ standalone commandline application, and also mixed in to other \n applications
|
43
|
+
as a module.\n"
|
42
44
|
email: kryptykfysh@kryptykfysh.co.uk
|
43
45
|
executables:
|
44
46
|
- dice
|
45
47
|
extensions: []
|
46
|
-
extra_rdoc_files:
|
48
|
+
extra_rdoc_files:
|
49
|
+
- README
|
47
50
|
files:
|
48
51
|
- bin/dice
|
49
|
-
- lib/physh_roller.rb
|
50
|
-
- lib/physh_roller/dice_roll.rb
|
51
52
|
- lib/physh_roller/die.rb
|
52
|
-
-
|
53
|
-
-
|
54
|
-
- spec/physh_roller/die_spec.rb
|
55
|
-
- doc/rdoc.css
|
56
|
-
- doc/doc/created_rid.html
|
57
|
-
- doc/PhyshRoller.html
|
58
|
-
- doc/images/tag_blue.png
|
59
|
-
- doc/images/plugin.png
|
60
|
-
- doc/images/wrench_orange.png
|
61
|
-
- doc/images/bullet_toggle_plus.png
|
62
|
-
- doc/images/transparent.png
|
63
|
-
- doc/images/find.png
|
64
|
-
- doc/images/macFFBgHack.png
|
65
|
-
- doc/images/bullet_black.png
|
66
|
-
- doc/images/page_white_text.png
|
67
|
-
- doc/images/loadingAnimation.gif
|
68
|
-
- doc/images/ruby.png
|
69
|
-
- doc/images/zoom.png
|
70
|
-
- doc/images/brick.png
|
71
|
-
- doc/images/bullet_toggle_minus.png
|
72
|
-
- doc/images/wrench.png
|
73
|
-
- doc/images/page_green.png
|
74
|
-
- doc/images/add.png
|
75
|
-
- doc/images/tag_green.png
|
76
|
-
- doc/images/brick_link.png
|
77
|
-
- doc/images/package.png
|
78
|
-
- doc/images/bug.png
|
79
|
-
- doc/images/delete.png
|
80
|
-
- doc/images/date.png
|
81
|
-
- doc/images/page_white_width.png
|
82
|
-
- doc/images/arrow_up.png
|
83
|
-
- doc/table_of_contents.html
|
84
|
-
- doc/PhyshRoller/DiceRoll.html
|
85
|
-
- doc/PhyshRoller/Die.html
|
86
|
-
- doc/features/physh_roller/roll_dice_feature.html
|
87
|
-
- doc/features/physh_roller/parse_dice_roll_string_feature.html
|
88
|
-
- doc/features/physh_roller/roll_die_feature.html
|
89
|
-
- doc/Output.html
|
90
|
-
- doc/Object.html
|
91
|
-
- doc/js/searcher.js
|
92
|
-
- doc/js/darkfish.js
|
93
|
-
- doc/js/search.js
|
94
|
-
- doc/js/navigation.js
|
95
|
-
- doc/js/search_index.js
|
96
|
-
- doc/js/jquery.js
|
97
|
-
- doc/index.html
|
98
|
-
- doc/created.rid
|
99
|
-
- features/step_definitions/physh_roller/physh_roller_steps.rb
|
100
|
-
- features/support/env.rb
|
101
|
-
- features/physh_roller/roll_dice.feature
|
102
|
-
- features/physh_roller/roll_die.feature
|
103
|
-
- features/physh_roller/parse_dice_roll_string.feature
|
53
|
+
- lib/physh_roller/dice_roll.rb
|
54
|
+
- lib/physh_roller.rb
|
104
55
|
- LICENSE
|
105
56
|
- README
|
57
|
+
- spec/physh_roller/die_spec.rb
|
58
|
+
- spec/physh_roller/dice_roll_spec.rb
|
59
|
+
- spec/spec_helper.rb
|
106
60
|
homepage: https://github.com/kryptykfysh/PhyshRoller
|
107
61
|
licenses:
|
108
62
|
- MIT
|
109
63
|
metadata: {}
|
110
|
-
post_install_message:
|
64
|
+
post_install_message: Thanks for installing PhyshRoller!
|
111
65
|
rdoc_options: []
|
112
66
|
require_paths:
|
113
67
|
- lib
|
@@ -123,11 +77,11 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
123
77
|
version: '0'
|
124
78
|
requirements: []
|
125
79
|
rubyforge_project:
|
126
|
-
rubygems_version: 2.0.0
|
80
|
+
rubygems_version: 2.0.0
|
127
81
|
signing_key:
|
128
82
|
specification_version: 4
|
129
83
|
summary: A dice rolling application
|
130
84
|
test_files:
|
131
|
-
- spec/spec_helper.rb
|
132
|
-
- spec/physh_roller/dice_roll_spec.rb
|
133
85
|
- spec/physh_roller/die_spec.rb
|
86
|
+
- spec/physh_roller/dice_roll_spec.rb
|
87
|
+
- spec/spec_helper.rb
|
data/doc/Object.html
DELETED
@@ -1,204 +0,0 @@
|
|
1
|
-
<!DOCTYPE html>
|
2
|
-
|
3
|
-
<html>
|
4
|
-
<head>
|
5
|
-
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
|
6
|
-
|
7
|
-
<title>class Object - RDoc Documentation</title>
|
8
|
-
|
9
|
-
<link type="text/css" media="screen" href="./rdoc.css" rel="stylesheet">
|
10
|
-
|
11
|
-
<script type="text/javascript">
|
12
|
-
var rdoc_rel_prefix = "./";
|
13
|
-
</script>
|
14
|
-
|
15
|
-
<script type="text/javascript" charset="utf-8" src="./js/jquery.js"></script>
|
16
|
-
<script type="text/javascript" charset="utf-8" src="./js/navigation.js"></script>
|
17
|
-
<script type="text/javascript" charset="utf-8" src="./js/search_index.js"></script>
|
18
|
-
<script type="text/javascript" charset="utf-8" src="./js/search.js"></script>
|
19
|
-
<script type="text/javascript" charset="utf-8" src="./js/searcher.js"></script>
|
20
|
-
<script type="text/javascript" charset="utf-8" src="./js/darkfish.js"></script>
|
21
|
-
|
22
|
-
|
23
|
-
<body id="top" class="class">
|
24
|
-
<nav id="metadata">
|
25
|
-
<nav id="home-section" class="section">
|
26
|
-
<h3 class="section-header">
|
27
|
-
<a href="./index.html">Home</a>
|
28
|
-
<a href="./table_of_contents.html#classes">Classes</a>
|
29
|
-
<a href="./table_of_contents.html#methods">Methods</a>
|
30
|
-
</h3>
|
31
|
-
</nav>
|
32
|
-
|
33
|
-
|
34
|
-
<nav id="search-section" class="section project-section" class="initially-hidden">
|
35
|
-
<form action="#" method="get" accept-charset="utf-8">
|
36
|
-
<h3 class="section-header">
|
37
|
-
<input type="text" name="search" placeholder="Search" id="search-field"
|
38
|
-
title="Type to search, Up and Down to navigate, Enter to load">
|
39
|
-
</h3>
|
40
|
-
</form>
|
41
|
-
|
42
|
-
<ul id="search-results" class="initially-hidden"></ul>
|
43
|
-
</nav>
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
<div id="file-metadata">
|
49
|
-
<nav id="file-list-section" class="section">
|
50
|
-
<h3 class="section-header">Defined In</h3>
|
51
|
-
<ul>
|
52
|
-
<li>features/step_definitions/physh_roller/physh_roller_steps.rb
|
53
|
-
<li>spec/spec_helper.rb
|
54
|
-
</ul>
|
55
|
-
</nav>
|
56
|
-
|
57
|
-
|
58
|
-
</div>
|
59
|
-
|
60
|
-
<div id="class-metadata">
|
61
|
-
|
62
|
-
<nav id="parent-class-section" class="section">
|
63
|
-
<h3 class="section-header">Parent</h3>
|
64
|
-
|
65
|
-
<p class="link">BasicObject
|
66
|
-
|
67
|
-
</nav>
|
68
|
-
|
69
|
-
<!-- Included Modules -->
|
70
|
-
<nav id="includes-section" class="section">
|
71
|
-
<h3 class="section-header">Included Modules</h3>
|
72
|
-
|
73
|
-
<ul class="link-list">
|
74
|
-
|
75
|
-
|
76
|
-
<li><span class="include">RSpec::Matchers</span>
|
77
|
-
|
78
|
-
|
79
|
-
</ul>
|
80
|
-
</nav>
|
81
|
-
|
82
|
-
|
83
|
-
<!-- Method Quickref -->
|
84
|
-
<nav id="method-list-section" class="section">
|
85
|
-
<h3 class="section-header">Methods</h3>
|
86
|
-
|
87
|
-
<ul class="link-list">
|
88
|
-
|
89
|
-
<li ><a href="#method-i-output">#output</a>
|
90
|
-
|
91
|
-
</ul>
|
92
|
-
</nav>
|
93
|
-
|
94
|
-
</div>
|
95
|
-
|
96
|
-
<div id="project-metadata">
|
97
|
-
<nav id="fileindex-section" class="section project-section">
|
98
|
-
<h3 class="section-header">Pages</h3>
|
99
|
-
|
100
|
-
<ul>
|
101
|
-
|
102
|
-
<li class="file"><a href="./doc/created_rid.html">created.rid</a>
|
103
|
-
|
104
|
-
<li class="file"><a href="./features/physh_roller/parse_dice_roll_string_feature.html">parse_dice_roll_string.feature</a>
|
105
|
-
|
106
|
-
<li class="file"><a href="./features/physh_roller/roll_dice_feature.html">roll_dice.feature</a>
|
107
|
-
|
108
|
-
<li class="file"><a href="./features/physh_roller/roll_die_feature.html">roll_die.feature</a>
|
109
|
-
|
110
|
-
</ul>
|
111
|
-
</nav>
|
112
|
-
|
113
|
-
<nav id="classindex-section" class="section project-section">
|
114
|
-
<h3 class="section-header">Class and Module Index</h3>
|
115
|
-
|
116
|
-
<ul class="link-list">
|
117
|
-
|
118
|
-
<li><a href="./Object.html">Object</a>
|
119
|
-
|
120
|
-
<li><a href="./Output.html">Output</a>
|
121
|
-
|
122
|
-
<li><a href="./PhyshRoller.html">PhyshRoller</a>
|
123
|
-
|
124
|
-
<li><a href="./PhyshRoller/DiceRoll.html">PhyshRoller::DiceRoll</a>
|
125
|
-
|
126
|
-
<li><a href="./PhyshRoller/Die.html">PhyshRoller::Die</a>
|
127
|
-
|
128
|
-
</ul>
|
129
|
-
</nav>
|
130
|
-
|
131
|
-
</div>
|
132
|
-
</nav>
|
133
|
-
|
134
|
-
<div id="documentation">
|
135
|
-
<h1 class="class">class Object</h1>
|
136
|
-
|
137
|
-
<div id="description" class="description">
|
138
|
-
|
139
|
-
</div><!-- description -->
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
<section id="5Buntitled-5D" class="documentation-section">
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
<!-- Methods -->
|
154
|
-
|
155
|
-
<section id="public-instance-5Buntitled-5D-method-details" class="method-section section">
|
156
|
-
<h3 class="section-header">Public Instance Methods</h3>
|
157
|
-
|
158
|
-
|
159
|
-
<div id="method-i-output" class="method-detail ">
|
160
|
-
|
161
|
-
<div class="method-heading">
|
162
|
-
<span class="method-name">output</span><span
|
163
|
-
class="method-args">()</span>
|
164
|
-
|
165
|
-
<span class="method-click-advice">click to toggle source</span>
|
166
|
-
|
167
|
-
</div>
|
168
|
-
|
169
|
-
|
170
|
-
<div class="method-description">
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
<div class="method-source-code" id="output-source">
|
178
|
-
<pre><span class="ruby-comment"># File features/step_definitions/physh_roller/physh_roller_steps.rb, line 11</span>
|
179
|
-
<span class="ruby-keyword">def</span> <span class="ruby-identifier">output</span>
|
180
|
-
<span class="ruby-ivar">@output</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">Output</span>.<span class="ruby-identifier">new</span>
|
181
|
-
<span class="ruby-keyword">end</span></pre>
|
182
|
-
</div><!-- output-source -->
|
183
|
-
|
184
|
-
</div>
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
</div><!-- output-method -->
|
190
|
-
|
191
|
-
|
192
|
-
</section><!-- public-instance-method-details -->
|
193
|
-
|
194
|
-
</section><!-- 5Buntitled-5D -->
|
195
|
-
|
196
|
-
</div><!-- documentation -->
|
197
|
-
|
198
|
-
|
199
|
-
<footer id="validator-badges">
|
200
|
-
<p><a href="http://validator.w3.org/check/referer">[Validate]</a>
|
201
|
-
<p>Generated by <a href="https://github.com/rdoc/rdoc">RDoc</a> 4.0.0.
|
202
|
-
<p>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish Rdoc Generator</a> 3.
|
203
|
-
</footer>
|
204
|
-
|
data/doc/Output.html
DELETED
@@ -1,226 +0,0 @@
|
|
1
|
-
<!DOCTYPE html>
|
2
|
-
|
3
|
-
<html>
|
4
|
-
<head>
|
5
|
-
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
|
6
|
-
|
7
|
-
<title>class Output - RDoc Documentation</title>
|
8
|
-
|
9
|
-
<link type="text/css" media="screen" href="./rdoc.css" rel="stylesheet">
|
10
|
-
|
11
|
-
<script type="text/javascript">
|
12
|
-
var rdoc_rel_prefix = "./";
|
13
|
-
</script>
|
14
|
-
|
15
|
-
<script type="text/javascript" charset="utf-8" src="./js/jquery.js"></script>
|
16
|
-
<script type="text/javascript" charset="utf-8" src="./js/navigation.js"></script>
|
17
|
-
<script type="text/javascript" charset="utf-8" src="./js/search_index.js"></script>
|
18
|
-
<script type="text/javascript" charset="utf-8" src="./js/search.js"></script>
|
19
|
-
<script type="text/javascript" charset="utf-8" src="./js/searcher.js"></script>
|
20
|
-
<script type="text/javascript" charset="utf-8" src="./js/darkfish.js"></script>
|
21
|
-
|
22
|
-
|
23
|
-
<body id="top" class="class">
|
24
|
-
<nav id="metadata">
|
25
|
-
<nav id="home-section" class="section">
|
26
|
-
<h3 class="section-header">
|
27
|
-
<a href="./index.html">Home</a>
|
28
|
-
<a href="./table_of_contents.html#classes">Classes</a>
|
29
|
-
<a href="./table_of_contents.html#methods">Methods</a>
|
30
|
-
</h3>
|
31
|
-
</nav>
|
32
|
-
|
33
|
-
|
34
|
-
<nav id="search-section" class="section project-section" class="initially-hidden">
|
35
|
-
<form action="#" method="get" accept-charset="utf-8">
|
36
|
-
<h3 class="section-header">
|
37
|
-
<input type="text" name="search" placeholder="Search" id="search-field"
|
38
|
-
title="Type to search, Up and Down to navigate, Enter to load">
|
39
|
-
</h3>
|
40
|
-
</form>
|
41
|
-
|
42
|
-
<ul id="search-results" class="initially-hidden"></ul>
|
43
|
-
</nav>
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
<div id="file-metadata">
|
49
|
-
<nav id="file-list-section" class="section">
|
50
|
-
<h3 class="section-header">Defined In</h3>
|
51
|
-
<ul>
|
52
|
-
<li>features/step_definitions/physh_roller/physh_roller_steps.rb
|
53
|
-
</ul>
|
54
|
-
</nav>
|
55
|
-
|
56
|
-
|
57
|
-
</div>
|
58
|
-
|
59
|
-
<div id="class-metadata">
|
60
|
-
|
61
|
-
<nav id="parent-class-section" class="section">
|
62
|
-
<h3 class="section-header">Parent</h3>
|
63
|
-
|
64
|
-
<p class="link"><a href="Object.html">Object</a>
|
65
|
-
|
66
|
-
</nav>
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
<!-- Method Quickref -->
|
71
|
-
<nav id="method-list-section" class="section">
|
72
|
-
<h3 class="section-header">Methods</h3>
|
73
|
-
|
74
|
-
<ul class="link-list">
|
75
|
-
|
76
|
-
<li ><a href="#method-i-messages">#messages</a>
|
77
|
-
|
78
|
-
<li ><a href="#method-i-puts">#puts</a>
|
79
|
-
|
80
|
-
</ul>
|
81
|
-
</nav>
|
82
|
-
|
83
|
-
</div>
|
84
|
-
|
85
|
-
<div id="project-metadata">
|
86
|
-
<nav id="fileindex-section" class="section project-section">
|
87
|
-
<h3 class="section-header">Pages</h3>
|
88
|
-
|
89
|
-
<ul>
|
90
|
-
|
91
|
-
<li class="file"><a href="./doc/created_rid.html">created.rid</a>
|
92
|
-
|
93
|
-
<li class="file"><a href="./features/physh_roller/parse_dice_roll_string_feature.html">parse_dice_roll_string.feature</a>
|
94
|
-
|
95
|
-
<li class="file"><a href="./features/physh_roller/roll_dice_feature.html">roll_dice.feature</a>
|
96
|
-
|
97
|
-
<li class="file"><a href="./features/physh_roller/roll_die_feature.html">roll_die.feature</a>
|
98
|
-
|
99
|
-
</ul>
|
100
|
-
</nav>
|
101
|
-
|
102
|
-
<nav id="classindex-section" class="section project-section">
|
103
|
-
<h3 class="section-header">Class and Module Index</h3>
|
104
|
-
|
105
|
-
<ul class="link-list">
|
106
|
-
|
107
|
-
<li><a href="./Object.html">Object</a>
|
108
|
-
|
109
|
-
<li><a href="./Output.html">Output</a>
|
110
|
-
|
111
|
-
<li><a href="./PhyshRoller.html">PhyshRoller</a>
|
112
|
-
|
113
|
-
<li><a href="./PhyshRoller/DiceRoll.html">PhyshRoller::DiceRoll</a>
|
114
|
-
|
115
|
-
<li><a href="./PhyshRoller/Die.html">PhyshRoller::Die</a>
|
116
|
-
|
117
|
-
</ul>
|
118
|
-
</nav>
|
119
|
-
|
120
|
-
</div>
|
121
|
-
</nav>
|
122
|
-
|
123
|
-
<div id="documentation">
|
124
|
-
<h1 class="class">class Output</h1>
|
125
|
-
|
126
|
-
<div id="description" class="description">
|
127
|
-
|
128
|
-
</div><!-- description -->
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
<section id="5Buntitled-5D" class="documentation-section">
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
<!-- Methods -->
|
143
|
-
|
144
|
-
<section id="public-instance-5Buntitled-5D-method-details" class="method-section section">
|
145
|
-
<h3 class="section-header">Public Instance Methods</h3>
|
146
|
-
|
147
|
-
|
148
|
-
<div id="method-i-messages" class="method-detail ">
|
149
|
-
|
150
|
-
<div class="method-heading">
|
151
|
-
<span class="method-name">messages</span><span
|
152
|
-
class="method-args">()</span>
|
153
|
-
|
154
|
-
<span class="method-click-advice">click to toggle source</span>
|
155
|
-
|
156
|
-
</div>
|
157
|
-
|
158
|
-
|
159
|
-
<div class="method-description">
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
<div class="method-source-code" id="messages-source">
|
167
|
-
<pre><span class="ruby-comment"># File features/step_definitions/physh_roller/physh_roller_steps.rb, line 2</span>
|
168
|
-
<span class="ruby-keyword">def</span> <span class="ruby-identifier">messages</span>
|
169
|
-
<span class="ruby-ivar">@messages</span> = []
|
170
|
-
<span class="ruby-keyword">end</span></pre>
|
171
|
-
</div><!-- messages-source -->
|
172
|
-
|
173
|
-
</div>
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
</div><!-- messages-method -->
|
179
|
-
|
180
|
-
|
181
|
-
<div id="method-i-puts" class="method-detail ">
|
182
|
-
|
183
|
-
<div class="method-heading">
|
184
|
-
<span class="method-name">puts</span><span
|
185
|
-
class="method-args">(message)</span>
|
186
|
-
|
187
|
-
<span class="method-click-advice">click to toggle source</span>
|
188
|
-
|
189
|
-
</div>
|
190
|
-
|
191
|
-
|
192
|
-
<div class="method-description">
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
<div class="method-source-code" id="puts-source">
|
200
|
-
<pre><span class="ruby-comment"># File features/step_definitions/physh_roller/physh_roller_steps.rb, line 6</span>
|
201
|
-
<span class="ruby-keyword">def</span> <span class="ruby-identifier">puts</span>(<span class="ruby-identifier">message</span>)
|
202
|
-
<span class="ruby-identifier">messages</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">message</span>
|
203
|
-
<span class="ruby-keyword">end</span></pre>
|
204
|
-
</div><!-- puts-source -->
|
205
|
-
|
206
|
-
</div>
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
</div><!-- puts-method -->
|
212
|
-
|
213
|
-
|
214
|
-
</section><!-- public-instance-method-details -->
|
215
|
-
|
216
|
-
</section><!-- 5Buntitled-5D -->
|
217
|
-
|
218
|
-
</div><!-- documentation -->
|
219
|
-
|
220
|
-
|
221
|
-
<footer id="validator-badges">
|
222
|
-
<p><a href="http://validator.w3.org/check/referer">[Validate]</a>
|
223
|
-
<p>Generated by <a href="https://github.com/rdoc/rdoc">RDoc</a> 4.0.0.
|
224
|
-
<p>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish Rdoc Generator</a> 3.
|
225
|
-
</footer>
|
226
|
-
|