Class: DieRoller

Inherits:
Object
  • Object
show all
Defined in:
lib/util/dieroller.rb

Instance Method Summary collapse

Instance Method Details

#roll(num_sides, modifier = 0) ⇒ Object



2
3
4
# File 'lib/util/dieroller.rb', line 2

def roll(num_sides, modifier=0)
  rand(num_sides) + 1 + modifier
end