Class: Die
- Inherits:
-
Object
- Object
- Die
- Defined in:
- lib/text_game/die.rb
Instance Method Summary collapse
-
#initialize ⇒ Die
constructor
A new instance of Die.
- #roll ⇒ Object
Constructor Details
#initialize ⇒ Die
Returns a new instance of Die.
2 3 |
# File 'lib/text_game/die.rb', line 2 def initialize end |
Instance Method Details
#roll ⇒ Object
4 5 6 |
# File 'lib/text_game/die.rb', line 4 def roll rand(1..6) end |