Class: Minesweeper::Core::Elements::HiddenState
- Inherits:
-
Object
- Object
- Minesweeper::Core::Elements::HiddenState
- Defined in:
- lib/minesweeper/core/elements/hidden_state.rb
Instance Method Summary collapse
Instance Method Details
#flag(cell) ⇒ Object
10 11 12 |
# File 'lib/minesweeper/core/elements/hidden_state.rb', line 10 def flag(cell) cell.current_state = CellState::FLAGGED_STATE end |
#reveal(cell) ⇒ Object
5 6 7 8 |
# File 'lib/minesweeper/core/elements/hidden_state.rb', line 5 def reveal(cell) cell.current_state = CellState::REVEALED_STATE cell.trigger end |
#to_s ⇒ Object
14 15 16 |
# File 'lib/minesweeper/core/elements/hidden_state.rb', line 14 def to_s "H" end |