Class: Pacman::GameOverController

Inherits:
ApplicationController show all
Defined in:
app/controllers/game_over_controller.rb

Instance Method Summary collapse

Instance Method Details

#restartObject



15
16
17
18
# File 'app/controllers/game_over_controller.rb', line 15

def restart
  state(:game, GameState).world = nil
  navigate_to "/game"
end

#showObject



8
9
10
11
12
13
# File 'app/controllers/game_over_controller.rb', line 8

def show
  render :show,
    game_over: game_over,
    high_scores: HighScore.top(5).to_a,
    palette: command_palette
end