# Linux Question: Emacs Game?

**URL:** <https://boards.straightdope.com/t/linux-question-emacs-game/100049>\
**Category:** Factual Questions\
**Created:** [March 25, 2002, 6:54pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049 "2002-03-25T18:54:25Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![sdimbert](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sdimbert/32/20204_2.png) [@sdimbert](https://boards.straightdope.com/u/sdimbert)\
**Post date:** [March 25, 2002, 6:54pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/1 "2002-03-25T18:54:25Z")

</div>

I’m a newbie to Linux, but I found a How-To that gave me a command to open an old text-adventure game in Emacs. It was the game that starts with, “You are standing on a dusty road.”

I can’t remember what the command was and I can’t find my way back to the directions.

Can anyone help me out?

---

<div class="post-metadata">

**Author:** ![Terminus\_Est](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/terminus_est/32/3087_2.png) [@Terminus\_Est](https://boards.straightdope.com/u/Terminus_Est)\
**Post date:** [March 25, 2002, 7:16pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/2 "2002-03-25T19:16:23Z")

</div>

M-x dunnet

```auto

Dead end
You are at a dead end of a dirt road. The road goes to the east.
In the distance you can see that it will eventually fork off. The
trees here are very tall royal palms, and they are spaced equidistant
from each other.
There is a shovel here.
>

```

---

<div class="post-metadata">

**Author:** ![sdimbert](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sdimbert/32/20204_2.png) [@sdimbert](https://boards.straightdope.com/u/sdimbert)\
**Post date:** [March 25, 2002, 7:55pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/3 "2002-03-25T19:55:16Z")

</div>

> [@](#):
>
> \*Originally posted by Terminus Est \*  
> **M-x dunnet**

Hmmmmmmm…

```auto

[sdimbert@intranet sdimbert]$ M-x dunnet
bash: M-x: command not found
[sdimbert@intranet sdimbert]$   

```

😕

---

<div class="post-metadata">

**Author:** ![Terminus\_Est](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/terminus_est/32/3087_2.png) [@Terminus\_Est](https://boards.straightdope.com/u/Terminus_Est)\
**Post date:** [March 25, 2002, 8:02pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/4 "2002-03-25T20:02:02Z")

</div>

You said **emacs** , right? Open up emacs or xemacs and type \<ESC\>, x, dunnet, \<RETURN\>.

```auto

>examine tree
They are palm trees with a bountiful supply of coconuts in them.
>shake tree
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.
You are dead.
You have scored 0 out of a possible 90 points.

```

---

<div class="post-metadata">

**Author:** ![sdimbert](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sdimbert/32/20204_2.png) [@sdimbert](https://boards.straightdope.com/u/sdimbert)\
**Post date:** [March 25, 2002, 8:49pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/5 "2002-03-25T20:49:29Z")

</div>

> [@](#):
>
> \*Originally posted by Terminus Est \*  
> \*\*You said **emacs** , right? Open up emacs or xemacs and type \<ESC\>, x, dunnet, \<RETURN\>. \*\*

OK - I’ve tried that, as well as \<ctrl\>-x, dunnet, \<return\>. Not working. Grrr…

Any idea what the second modifier key is (after \<ctrl\>) in a telnet session?

---

<div class="post-metadata">

**Author:** ![Terminus\_Est](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/terminus_est/32/3087_2.png) [@Terminus\_Est](https://boards.straightdope.com/u/Terminus_Est)\
**Post date:** [March 25, 2002, 9:04pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/6 "2002-03-25T21:04:36Z")

</div>

That would be the ESC or Meta key. You have to _release_ the ESC key before pressing ‘x’.

[list=1]  
[li]Press ESC and release it.[/li][li]Press ‘x’ and release it. (It should now say ‘M-x’ at the bottom of your screen.)[/li][li]Type ‘dunnet’ and hit return.[/li][/list=1]

Posting any error messages might be useful.

---

<div class="post-metadata">

**Author:** ![SDP](https://avatars.discourse-cdn.com/v4/letter/s/e95f7d/32.png) [@SDP](https://boards.straightdope.com/u/SDP)\
**Post date:** [March 25, 2002, 9:14pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/7 "2002-03-25T21:14:33Z")

</div>

What do you usually use as the meta (M- ) key? I was under the impression that escape should work in all but the most dire of situations. It is possible that dunnet is not installed – try some other games, like M-x tetris, and see if they work. Here is from the emacs manual:

> [@](#):
>
> # Other Amusements
> 
> If you are a little bit bored, you can try `M-x hanoi’. If you are  
> considerably bored, give it a numeric argument. If you are very, very  
> bored, try an argument of 9. Sit back and watch.
> 
> If you want a little more personal involvement, try `M-x gomoku’,  
> which plays the game Go Moku with you.
> 
> `M-x blackbox', `M-x mpuz’ and `M-x 5x5' are kinds of puzzles. `blackbox’ challenges you to determine the location of objects inside a  
> box by tomography. `mpuz' displays a multiplication puzzle with letters standing for digits in a code that you must guess--to guess a value, type a letter and then the digit you think it stands for. The aim of `5x5’ is to fill in all the squares.
> 
> `M-x decipher’ helps you to cryptanalyze a buffer which is encrypted  
> in a simple monoalphabetic substitution cipher.
> 
> `M-x dunnet’ runs an adventure-style exploration game, which is a  
> bigger sort of puzzle.
> 
> `M-x lm’ runs a relatively non-participatory game in which a robot  
> attempts to maneuver towards a tree at the center of the window based on  
> unique olfactory cues from each of the four directions.
> 
> `M-x life’ runs Conway’s “Life” cellular automaton.
> 
> `M-x morse-region' converts text in a region to Morse code and `M-x  
> unmorse-region’ converts it back. No cause for remorse.
> 
> `M-x pong’ plays a Pong-like game, bouncing the ball off opposing  
> bats.
> 
> `M-x solitaire’ plays a game of solitaire in which you jump pegs  
> across other pegs.
> 
> `M-x studlify-region’ studlify-cases the region, producing text like  
> this:
> 
> ```
> M-x stUdlIfY-RegioN stUdlIfY-CaSeS thE region.
> 
> ```
> 
> `M-x tetris' runs an implementation of the well-known Tetris game. Likewise, `M-x snake’ provides an implementation of Snake.
> 
> When you are frustrated, try the famous Eliza program. Just do `M-x  
> doctor’. End each input by typing \<RET\> twice.
> 
> When you are feeling strange, type `M-x yow’.
> 
> The command `M-x zone’ plays games with the display when Emacs is  
> idle.

---

<div class="post-metadata">

**Author:** ![sdimbert](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sdimbert/32/20204_2.png) [@sdimbert](https://boards.straightdope.com/u/sdimbert)\
**Post date:** [March 25, 2002, 9:21pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/8 "2002-03-25T21:21:59Z")

</div>

OK - Your suggestion worked. Sort of. LooK:

```auto

Buffers Files Tools Edit Search Mule Help
Dead end
You are at a dead end of a dirt road. The road goes to the east.
In the distance you can see that it will eventually fork off. The
trees here are very tall royal palms, and they are spaced equidistant
from each other. C-h t Use Info to read docs C-h i
There is a shovel here. or ESC ` or M-`
>`C-' means use the CTRL key. `M-' means use the Meta (or Alt) key.
If you have no Meta key, you may instead type ESC followed by the character.)

GNU Emacs 20.7.1 (i386-redhat-linux-gnu, X toolkit)
 of Thu Aug 24 2000 on porky.devel.redhat.com
Copyright (C) 1999 Free Software Foundation, Inc.

GNU Emacs comes with ABSOLUTELY NO WARRANTY; type C-h C-w for full details.
Emacs is Free Software--Free as in Freedom--so you can redistribute copies
of Emacs and modify it; type C-h C-c to see the conditions.
Type C-h C-d for information on getting the latest version.

--11:**-F1 *dungeon* (Dungeon)--L7--All--------------------------------
Mark set
                                                                               

```

It’s kind of hard to see, but dunnets appeared in the middle of the welcome-crap that emacs starts up with. The other command I remember ended up getting me dunnets right from the command line. Anyone know what I mean?

---

<div class="post-metadata">

**Author:** ![Terminus\_Est](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/terminus_est/32/3087_2.png) [@Terminus\_Est](https://boards.straightdope.com/u/Terminus_Est)\
**Post date:** [March 25, 2002, 9:27pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/9 "2002-03-25T21:27:59Z")

</div>

Looks like you have a broken terminal implementation. Two questions: What does it say when you type ‘echo $TERM’ at the command line? and what are you using to telnet to the linux box?

---

<div class="post-metadata">

**Author:** ![sdimbert](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sdimbert/32/20204_2.png) [@sdimbert](https://boards.straightdope.com/u/sdimbert)\
**Post date:** [March 25, 2002, 9:34pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/10 "2002-03-25T21:34:48Z")

</div>

> [@](#):
>
> \*Originally posted by Terminus Est \*  
> \*\*Looks like you have a broken terminal implementation. Two questions: What does it say when you type ‘echo $TERM’ at the command line? and what are you using to telnet to the linux box? \*\*

```auto

[sdimbert@intranet sdimbert]$ echo $TERM
ansi 

```

To telnet, I’m just using DOS’s telnet command.

---

<div class="post-metadata">

**Author:** ![Terminus\_Est](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/terminus_est/32/3087_2.png) [@Terminus\_Est](https://boards.straightdope.com/u/Terminus_Est)\
**Post date:** [March 25, 2002, 9:47pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/11 "2002-03-25T21:47:01Z")

</div>

> [@](#):
>
> \*Originally posted by sdimbert \*  
> \*\*  
> To telnet, I’m just using DOS’s telnet command. \*\*

UGH. It’s a wonder you got something vaguely intelligible out of emacs. You really need a decent VT100 emulator. Look around the web for TeraTerm or PuTTY.

---

<div class="post-metadata">

**Author:** ![sdimbert](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sdimbert/32/20204_2.png) [@sdimbert](https://boards.straightdope.com/u/sdimbert)\
**Post date:** [March 25, 2002, 10:09pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/12 "2002-03-25T22:09:48Z")

</div>

OK - I got TeraTerm Pro and I like it. And, I used dunnet’s manual to determine that:

```auto

- To run this game in batch mode (no emacs window), use:
     emacs -batch -l dunnet
NOTE: This game *should* be run in batch mode!

```

That’s what I wanted!

🙂

---

<div class="post-metadata">

**Author:** ![Terminus\_Est](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/terminus_est/32/3087_2.png) [@Terminus\_Est](https://boards.straightdope.com/u/Terminus_Est)\
**Post date:** [March 25, 2002, 10:19pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/13 "2002-03-25T22:19:14Z")

</div>

> [@](#):
>
> \*Originally posted by sdimbert \*  
> \*\*I used dunnet’s manual…  
> \*\*

:eek:  
You read the manual? 😃

---

<div class="post-metadata">

**Author:** ![Popup](https://avatars.discourse-cdn.com/v4/letter/p/94ad74/32.png) [@Popup](https://boards.straightdope.com/u/Popup)\
**Post date:** [March 26, 2002, 2:07pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/14 "2002-03-26T14:07:27Z")

</div>

> [@](#):
>
> \*Originally posted by SDP \*\*\*… try some other games, like M-x tetris, and see if they work. Here is from the emacs manual:
> 
> > [@](#):
> >
> > …If you want a little more personal involvement, try `M-x gomoku’, which plays the game Go Moku with you. …
> 
> \*\*

Thanks **SDP** for wasting an entire day for me. I had completely forgotten abut the GoMoku implementation, and now I can’t stop playing it. It’s pretty clever, but I can normally beat it if I get to start…

And **sdimbert** , let me just say that if you’d better be pretty confident with both bash and ftp shells, as well as DOS in order to get anywhere with _dunnet_. On the other hand, IBM mainframes can be broken into with an axe…

---

<div class="post-metadata">

**Author:** ![sdimbert](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sdimbert/32/20204_2.png) [@sdimbert](https://boards.straightdope.com/u/sdimbert)\
**Post date:** [March 26, 2002, 3:36pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/15 "2002-03-26T15:36:34Z")

</div>

> [@](#):
>
> \*Originally posted by Popup \*  
> \*\*And **sdimbert** , let me just say that if you’d better be pretty confident with both bash and ftp shells, as well as DOS in order to get anywhere with _dunnet_. On the other hand, IBM mainframes can be broken into with an axe… \*\*

Is this a hint? Because I’m stuck in the building at the end of the road. There’s a Mail Room (with nothing in it) and a Computer Room with a computer that doesn’t echo anything to the screen, no matter what I type.

I can’t find the axe. ☹

---

<div class="post-metadata">

**Author:** ![Popup](https://avatars.discourse-cdn.com/v4/letter/p/94ad74/32.png) [@Popup](https://boards.straightdope.com/u/Popup)\
**Post date:** [March 26, 2002, 4:24pm UTC](https://boards.straightdope.com/t/linux-question-emacs-game/100049/16 "2002-03-26T16:24:52Z")

</div>

Just some quick hints:  
[ul][li]You have a shovel, don’t you?[/li][li]And somewhere along the road, there was some soft ground?[/li][li]Maybe if you were to find a CPU card that you could put in the VAX it would boot?[/li][li]And maybe you could find something written in the mail bins.[/li][li]Some people use their last names as usernames, and first name as password. Very sloppy security![/li][li]And don’t forget to use ‘binary’ mode FTP - or the files will end up scrambled![/li][/ul]  
If you want more hints, I suggest you ask google. He knows just about everything.
