lib/games/mastermind/peg.rb in games_bfox-0.3.0 vs lib/games/mastermind/peg.rb in games_bfox-0.4.0

- old
+ new

@@ -1,12 +1,10 @@ module MM class Peg - attr_accessor :display_value, :row, :col + attr_accessor :display_value - def initialize(args) + def initialize(args = {}) @display_value = args.fetch(:display_value, nil) - @row = args[:row] - @col = args[:col] end def change_value(new_value) self.display_value = new_value end