Home · Examples 


Putting it all Together

Finally, we are ready to look at an example that brings what we have learned in this tutorial together. After this example, you can also check out the generator example, which uses the generator on a library for creating graphic adventure games.

Text Adventure Example

In keeping with the generator example, we will create an adventure game engine in C++ and map that to Java. However, we will venture a little longer back in time - to the eighties to be exact - when the text adventure had its days of glory.

Our text adventure library will contain a command parser, an object tree , and a collection of actions the player can make. The library consists of the following classes:

Example Java Game

In this section, we take a quick look at a Java game implemented using our text adventure library.

We have


Copyright © 2009 Nokia Corporation and/or its subsidiary(-ies) Trademarks
Qt Jambi 4.5.2_01