Class: Minesweeper::Cell
Instance Attribute Summary
Attributes inherited from BaseCell
Instance Method Summary collapse
Methods inherited from BaseCell
#initialize, #toggle_bomb_flag!
Constructor Details
This class inherits a constructor from Minesweeper::BaseCell
Instance Method Details
#bomb? ⇒ Boolean
5 6 7 |
# File 'lib/minesweeper/cell.rb', line 5 def bomb? false end |
#open!(number_of_boms_nearby) ⇒ Object
9 10 11 12 13 |
# File 'lib/minesweeper/cell.rb', line 9 def open!(number_of_boms_nearby) state.view = number_of_boms_nearby.to_s state.color = COLOR_CYAN state.status = :opened end |