Looking to build a text-based game engine

cassidoo profile image Cassidy Williams Mar 28, 2017

Hey friends!

I've been thinking about building a text-based game engine. Haven't played a text-based game in a while and thought I might make one myself!

So my main questions are: Have you built one (either an engine or a text-based game) before? Should I stop trying to reinvent the wheel, aka are there some solid open source engines out there already I should just use? What are your favorite text games?

markdown cheatsheet

Idk about engines, but it could be fun to do a modern spin on the game. Most of the Amazon Alexa skills are essentially text based games, but just spoken. IE: 20 questions/What Am I.. Open the Magic Door which was an adventure game. Idk check it out :)

I'm working on a text game engine in Python! It is a lot of work and I will likely be working on it for another decade lol.

I find it a really rewarding side project, mostly because I really enjoy trying to figure out weird things that users might want to implement in a text-based game and then figuring out how to make my engine able to accommodate that. That being said, if your main goal is just writing a text adventure and not the engine, you'll probably get more mileage out of just using Inform7 :)

Great looking project! I'm building an engine in JS and I'm always interested to see people's takes on structuring such a thing.

I'd encourage you to write your own if only for the learning process that comes with a personal project about which you're passionate.

Back in the day (!) there was a competition for a MUD in less than 16k of source code: andreasen.org/16k.shtml all the submitted entries are available to download and are in a (small) variety of languages. This could be an interesting place to get inspiration.

If my other half hadn't decided to enter this competition I don't think I would have ever got my head into the nuances of C ;)

As far as my favourite games go that's a tough one, most of the early games I played were text based, although there's a special place in my heart for Martello Tower as it was the first game I was allowed to play in school as a reward for finishing my work early :)

By this time there certainly should be some good engines! Adventure (the original) is at least 42 years old. I know there were versions where I say the original comments with dates from 1975!

From this Quora article there seem to be some free-ish engines:

quora.com/Im-searching-for-a-good-...

If you look at the original text based game engines (Adventure, Zork, etc) they were all basically finite-state-automata engines, with each room location as a node, and the moves as graph edges from room (node) to room. Usually there was room-specific code attached to each node for the possible actions within the room.

I built a similar engine in college many, many years ago. It's quite do-able with early college undergraduate programming skills. Sadly, that code is lost in the mists of time. On the other hand, its probably better that way :-)

So it depends, really.

Do you want to make a game, or do you want to learn to make a simple game engine? Either way, it will be fun, and you'll learn a lot!

Quest and Squiffy look like they might be what you're looking for.

textadventures.co.uk/quest

I'm building an engine in plain javascript and it's totally worth doing! I started working on it in order to get better at JS, but it's turned into a sandbox for learning architecture, unit testing, documentation, and a few other things, too. Whenever I want to learn something new, it's the first place I try those skills out.

I thought it was going to be a fairly simple project, but as I've added various mechanics and increased the scope of where I want it to go, it's become a much longer term project than I anticipated.

I highly recommend making an engine from scratch if you have the time and energy.

I liked the mystic lpmud style stuff ... MUDDs of all versions were great though!

Also, the spiritual successors like RENPY (python) are awesome - renpy.org/ - nothing like a choose your own adventure book :)

There's a few modern frameworks for MUD-type games that are being worked on. Evennia is one in python that's been great fun to play around with, though it's fairly bare-bones out of the box - it's up to you to design systems like combat and so on.

Inform is really nice and open source. inform7.com

You probably mean text input, but I really enjoyed these ones with an HP Lovecraft theme: play.google.com/store/apps/details...

I've dabbled a bit with inform7.com/ but never quite pulled the trigger on finishing something - I'm hoping 2017 will be the year!

I've had this one: github.com/pistacchio/Dedalus starred for awhile. It looks like a great engine for web-based Choose Your Adventure games.

It's possible using some chat bots frameworks to do something like a text based game.
try hubot! :D

hubot.github.com
hubot.coffee

Check Ink: inklestudios.com/ink/

It's a scripting language that was created to power 80 days.