2 releases

0.1.1 May 24, 2024
0.1.0 May 24, 2024

#40 in Games

MIT license

115KB
1.5K SLoC

Wump

Hunt the Wumpus

crates.io docs.rs

An old school character mode game screen

This is a revivification of the ancient & "legendary" computer game, Hunt the Wumpus, which seems to be the only kind of Rust project that I ever actually finish.

About the Game

About the Implementation

What

The implementation is based loosely on the C version included in the BSD Games package of the Debian Linux distribution. The comments suggest that it was written by Dave Taylor, of Intuitive Systems.

I chose this implementation over the original BASIC version by Gregory Yob because it was more readable (arguably).

This implementation is structured differently , but tries valiantly to work as similarly as possible to the source material. This includes using the text strings from the original & preserving the amusing & sometimes baffling comments.

Why

I had thought about this game for a not insubstantial amount of time, but I didn't have the same happy memories of the game that I did with the Star Trek game.

But, in thinking about it, I kept thinking about the map: a graph equivalent to the vertices of a dodecahedron. When I looked at the BASIC version, they just had a predetermined list of nodes & connections. I thought about writing a map generator, but didn't feel like writing the whole game (see comment above about happy memories).

Eventually, I decided to just make a dodecahedral map generator in Python, & then decided to write one in Rust, & then found myself writing the game.

Notes

  • I have not looked at the C version map generator & I don't understand how it works.
  • Because it is somehow wrapped up in the map generation, I don't understand how the "magic tunnel" code works, so, as of this writing, in my version it doesn't. Maybe I'll read the BASIC version & use that.
  • I have not done much testing, but it seems to work. Bugs could be a thing.
  • Because it uses my dodecahedron map, the C version's parameterized map generation is not something that this implementation currently does.
  • Maxwell Anderson wrote a version of this game in Rust two years before this one. You should probably be playing that.

Dependencies

~7–20MB
~240K SLoC