lib/gameboard/cell.rb in gameboard-3.5.0 vs lib/gameboard/cell.rb in gameboard-4.0.0
- old
+ new
@@ -1,23 +1,23 @@
require_relative './coordinate'
module Gameboard
class Cell
# Public: Returns the value of the Cell instance.
- attr_accessor :value
+ attr_accessor :val
# Public: Retuns the Coordinate of the Cell instance. Returns type
# Gameboard::Coordinate.
attr_reader :coord
# Public: Initialize the Cell.
#
# coord - A Coordinate class instance at postition X,Y.
# value - The cell's value.
#
- def initialize(coord: false, value: false)
+ def initialize(coord: false, val: false)
raise TypeError unless coord.is_a?(Coordinate)
- @value = value
+ @val = val
@coord = coord
end
end
end