Method: Monotony::Square#initialize
- Defined in:
- lib/monotony/square.rb
#initialize(opts) ⇒ Square
Returns a new instance of Square.
15 16 17 18 19 20 21 |
# File 'lib/monotony/square.rb', line 15 def initialize(opts) @owner = nil @set = opts[:set] || nil @name = opts[:name] @action = opts[:action] || Proc.new {|game, owner, player, property|} @colour = opts[:colour] || ( String.colors.include? opts[:set] ? opts[:set] : :light_black ) end |