Function: tetris
tetris is an autoloaded, interactive and byte-compiled function
defined in tetris.el.gz.
Signature
(tetris)
Documentation
Play the Tetris game.
Shapes drop from the top of the screen, and the user has to move and rotate the shape to fit in with those at the bottom of the screen so as to form complete rows.
tetris-mode keybindings:
n (tetris-start-game) Start a new game of Tetris
q (tetris-end-game) Terminate the current game
p (tetris-pause-game) Pause (or resume) the current game
<left> (tetris-move-left) Move the shape one square to the left
<right> (tetris-move-right) Move the shape one square to the right
<up> (tetris-rotate-prev) Rotate the shape clockwise
M-x tetris-rotate-next (tetris-rotate-next) Rotate the shape anticlockwise
SPC (tetris-move-bottom) Drop the shape to the bottom of the playing area
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/play/tetris.el.gz
;;;###autoload
(defun tetris ()
"Play the Tetris game.
Shapes drop from the top of the screen, and the user has to move and
rotate the shape to fit in with those at the bottom of the screen so
as to form complete rows.
`tetris-mode' keybindings:
\\<tetris-mode-map>
\\[tetris-start-game] Start a new game of Tetris
\\[tetris-end-game] Terminate the current game
\\[tetris-pause-game] Pause (or resume) the current game
\\[tetris-move-left] Move the shape one square to the left
\\[tetris-move-right] Move the shape one square to the right
\\[tetris-rotate-prev] Rotate the shape clockwise
\\[tetris-rotate-next] Rotate the shape anticlockwise
\\[tetris-move-bottom] Drop the shape to the bottom of the playing area"
(interactive)
(select-window (or (get-buffer-window tetris-buffer-name)
(selected-window)))
(switch-to-buffer tetris-buffer-name)
(gamegrid-kill-timer)
(tetris-mode)
(tetris-start-game))