Function: dun-shake
dun-shake is a byte-compiled function defined in dunnet.el.gz.
Signature
(dun-shake OBJ)
Source Code
;; Defined in /usr/src/emacs/lisp/play/dunnet.el.gz
(defun dun-shake (obj)
(let ((objnum (dun-objnum-from-args-std obj)))
(when objnum
(cond
((member objnum dun-inventory)
;; If shaking anything will do anything, put here.
(dun-mprinc "Shaking " (downcase (cadr (nth objnum dun-objects))))
(dun-mprincl " seems to have no effect."))
((and (not (member objnum (nth dun-current-room dun-room-silents)))
(not (member objnum (nth dun-current-room dun-room-objects))))
(dun-mprincl "I don't see that here."))
;; Shaking trees can be deadly
((= objnum obj-tree)
(dun-mprinc
"You begin to shake a tree, and notice a coconut begin to fall from the air.
As you try to get your hand up to block it, you feel the impact as it lands
on your head.")
(dun-die "a coconut"))
((= objnum obj-bear)
(dun-mprinc
"As you go up to the bear, it removes your head and places it on the ground.")
(dun-die "a bear"))
((< objnum 0) (dun-mprincl "You cannot shake that."))
(t (dun-mprincl "You don't have that."))))))