Chapter 3 - Starting Out Again
Starting a New GameIn the previous chapter we saw how to create a very simple TADS 3 game. In this chapter we shall start creating a somewhat more complex game, which will occupy us for the remainder of this guide. Although in the initial stages there will be some overlap with what has gone before, it is important to ensure that the foundations of understanding are securely laid, and in any case we shall shortly be introducing new ways of accomplishing seemingly familiar tasks.
Now open the file in your text editor of choice (either through Workbench or through the editor) and remove the definition of startroom, i.e. the lines that read:
"This is the starting room. "
Next, change the line location = startRoom (after the comment /* the initial location */) so that it reads location = outsideCottage. You might also like to fill in the other fields with something a bit more meaningful, so that the edited file looks something like:
IFID = '573a8b18-1008-ca66-9580-9a156f82eefa'
name = 'The Further Adventures of Heidi'
byline = 'by An Author'
htmlByline = 'by <a href="mailto:email@example.com">
version = '1.0'
authorEmail = 'ERIC EVE <firstname.lastname@example.org>'
desc = 'This is an unexciting tutorial game based loosely on
The Adventures of Heidi by Roger Firth and Sonja Kesserich.'
htmlDesc = 'This is an unexciting tutorial game based loosely on
<i>The Adventures of Heidi</i> by Roger Firth and Sonja Kesserich.'
/* show our credits */
"The TADS 3 language and library were created by Michael J.
|for the Inform language written by Roger Firth and Sonja Kesserich.";
"<i>The Further Adventures of Heidi</i><.p>
A Tutorial Game for TADS 3";
/* the initial location */
location = outsideCottage
initialPlayerChar = me
"Welcome to the Further Adventures of Heidi!\b";
"<.p>Thanks for playing!\b";
maxScore = 7
beforeRunsBeforeCheck = nil