1. About.com
  2. Computing & Technology
  3. Ruby

Discuss in my forum

Michael Morin

Making a Text Adventure Game in Ruby Part 1: One Tree to Rule Them All

By , About.com Guide   November 8, 2011

Follow me on:

You are standing in a field.  To your east is a small white house with a boarded front door.  There is a mailbox here.  What do you do?  To some of you, this is a familiar situation, it's the opening scene to the popular text adventure (AKA "interactive fiction") game Zork.  These games were deep and interesting games in a time when most games struggled to match Space Invaders and Asteroids.  How did they do this?  By not having graphics and letting your imagination do the heavy lifting.  You don't control your character with a joystick, you just type what you want to do and the game tells you what happens.

In this series of articles, we'll be making our own text adventure game in Ruby from scratch.  This first part explains how the whole thing will be powered:  from a single tree structure.

Comments
No comments yet. Leave a Comment
Leave a Comment

Line and paragraph breaks are automatic. Some HTML allowed: <a href="" title="">, <b>, <i>, <strike>

©2012 About.com. All rights reserved. 

A part of The New York Times Company.