BOTW: MUD Game Programming

This week I read MUD Game Programming by Rob Penton. I love the MUD genre because it combines three things I love:

  1. Role-playing.

  2. Simple text interfaces.

  3. Having fun with friends.

If you’ve never played a MUD then just imagine World of Warcraft except with no graphics. Some MUDs do have graphics, but most people consider the text-only interface as defining aspect of the genre. There are still MUDs out there with dedicated players and new ones continuing to appear.

Every programmer who’s a fan of a genre of games wants to create one of those games. I’d love to make a MUD. I could use an existing code-base, but if I wanted to write my own then it would be nice to have some help along the way. So how was MUD Game Programming in that regard?

The Good

Rob Penton groups the chapters of MUD Game Programming into three parts:

  1. The Basics
  2. Creating a SimpleMUD
  3. Creating a BetterMUD

‘The Basics’ begins with a crash course in network programming. It provides a concise but useful explanation of network layers, packets, the important differences between TCP and UDP—topics like that. It’s a great refresher about how to setup sockets and pass data back and forth. On top of explaining the technical how-to’s of using sockets, the author also gives educated reasoning for the methods the book presents, e.g. why UDP makes sense for a first-person shooter but not a MUD.

The author often uses diagrams and charts to explain the flow of data and structure of the game. He extends this practice to all chapters of the book and I found it to be a great aspect. I feel like programming books under-utilize visual depictions like the ones found in MUD Game Programming. Even though the MUD genre is heavily text-based the reader still benefits from graphical representations of rooms, maps, command loops, and so on.

Most of the book’s code is C++ and since it’s a decade old it does not reflect the modern style of C++ you would find in contemporary software. That said, the author takes care to explain relevant pitfalls that the reader should avoid. It is welcome advice, because no sane programmer could say with a straight face that C++ is not a loaded gun without a safety switch. The code is compact for the sake of fitting on the page but the naming conventions and overall style are nice and readable.

The Bad

If there is anything seriously wrong with the code it is that there is too much of it. It is reasonable to expect that a book titled MUD Game Programming will contain some amount of code, but the amount of code and explanation of its implementation far outweighs the discussion of game design elements. The second part of the book details the implementation of SimpleMUD, which has a fitting name. Here the author makes a number of arbitrary game design choices while spending little to no time talking about their ramifications. This is understandable since that part of the book is more concerned with teaching the technical details of implementing a MUD.

The third and final section talks about the creation of BetterMUD, which again is aptly named. Here the author dives into interesting territory by showing how to give a MUD flexibility in design by introducing Python as a scripting language. Yet again the book focuses too much on the technical implementation and invests little time in showing the reader the potential of this approach. The overwhelming majority of the text reads like a technical manual in how to program a MUD, but offers little in the way of why you would choose this or that design.

In Conclusion

MUD Game Programming is exactly what it claims to be: a text on programming a MUD. But its focus is strongly on the programming aspect and not the act of gameplay design that comes along with building a MUD. It is a wonderfully informative book for someone who already has gameplay ideas in mind but is missing the technical know-how to give those ideas life. But if you are searching for a discussion about the pros and cons of different game design choices then you will not find them within these pages.

Nonetheless, I still enjoyed reading MUD Game Programming. It was a nice refresher on network programming and it covered all of the programmatic aspects of MUDs that interested me. I would have preferred to see more debate about the merits of design, but the author’s tendency to focus more on code would not stop me from recommending this book to friends.

Next Book of the Week

Next I will be reading Data Structures and Algorithms in Java by Robert Lafore. I have a side-project in mind for which I intend to use Java and so I thought this would be a good time to read through this one.

Advertisements

One thought on “BOTW: MUD Game Programming

Add Your Thoughts

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s