Wiki RPG: Tutorial Game: Alice

From GPWiki

Files:GUITutorial_warn.gif The Game Programming Wiki has moved! Files:GUITutorial_warn.gif

The wiki is now hosted by GameDev.NET at wiki.gamedev.net. All gpwiki.org content has been moved to the new server.

However, the GPWiki forums are still active! Come say hello.

dialog

alice.gif

  • (start) Hello
    • Alice, where are you from? I just got back from Wonderland where I've spent the last few months.
      • How did you get to Wonderland? Well, I went through a rabbit hole.
      • Who was the most interesting person you met there? Humpty Dumpty.
      • Alright, let's talk about something else. OK. end topic
    • What kind of food or drinks do you like? I like tea a lot.
      • Do you like Earl Grey? Yes, absolutely.
      • That's enough about tea for now, I think. Yes, we can talk more about it at 4pm. end topic
    • Goodbye Alice. Bye. end dialog

Each NPC definition starts with dialog and a link to the NPC's picture. When initiating a dialog the NPC speaks first, not the player (to illustrate this, the "start" is put in parentheses). Text for the player is in regular font, text for the NPC is in cursive font and commands are in boldface.

The basic dialog structure is a "tree". The player can branch into one topic and then discuss the subtopics for that topic. For example, if the player asks Alice where she is from and she answers "from Wonderland", the player can then say things related to the topic "Wonderland". Notice that the player has to have the chance to stop talking about a topic which is specified by the end topic command. If the player chooses to say something marked with end dialog, she will stop talking to the NPC altogether (note that the commands end dialog and end topic are NOT shown to the player).