Menu-based conversation in I6

I’m trying to do a straightforward menu-based conversation system in my Inform 6 game. Like say, 90’s point and click adventures or Life is Strange.

Untli now I’ve been using gtalk.h from here because it came with a good example but as dialog is turning out to be a large part of the game, it’s starting to feel clunky to use.

  • All quips have to be defined in one giant switch statement on the NPC object. For organization it would be handy to be able to organize certain conversation trees in the chapter they happen.
  • “TALK TO PERSON” always invokes the same quip. Often, the starting conversation should depend on the context and where in the story we are. It’s possible to manage this by enabling/disabling main menu quips as we go, but it becomes a hassle.
  • QList/QXList(num, num, …) is a clunky way of defining sub-options, it makes it hard to see conversation flow.

I’m aware that the state of the art is likely to be Inform 7 only, but I have trouble wrapping my brain around that and besides I really prefer not to spend my spare creative time on learning another programming language :face_holding_back_tears:

Does anyone have suggestions? What do “modern” I6 games use? The game only targets Glulx, if that matters.

1 Like

I’ve never liked conversation trees as a player, so I’ve never implemented one as an author. I prefer to use TALK TO <character> and ASK <character> ABOUT <topic>.

You might want to take a look at the ext_talk_menu.h extension that comes with PunyInform. According to the user manual, this can be used with the Inform 6 standard library, so you don’t need to migrate to Puny if you don’t want to.

Quoting from the user manual:
“This extension lets you define a set of topics for each character which the player can talk to him or her about. The player can type “TALK TO (someone)” and get a menu of topics they can talk about. Each topic can unlock new topics, set flags (if you include ext_flags.h), and run routines.”


It doesn’t work with Glulx unfortunately.


Fair enough. One reason for me to choose conversation trees is because personally I get confused by anything too open-ended: guess-the-verb, guess-the-topic. Lack of discoverability in UI. But I can understand the other way around, too, if you see that as kind of a challenge in itself. Thinking of it, Blue Lacuna had a good compromise by highlighting the currently available topics (too bad it’s I7 and I can’t make head or tails of its code :smile: )

Also, the ability for the player character to give more elaborate responses that aren’t necessarily simply asking about a specific topic or yes/no, can be good at times. Though there are other ways to fit that in, I guess, that don’t involve “guess this arbitrary combination of words”.

In any case for this game I’m probably sticking with conversation trees, if I keep making conceptual changes I’ll never finish a game.

I’ll have a look at that, thanks! I haven’t looked at PunyInform at all because I expected it to make things harder and more low-level, not to add convenient extensions beyond the inform library !

Oh! That’s too bad. Well I think it’s still useful for inspiration. I’m mostly looking at ideas how to structure so it doesn’t become a complete mess, I’ll figure out the window handling.

1 Like

We have a plan to add Glulx support for this as well. We just haven’t prioritized it yet. PunyInform doesn’t support Glulx, but we want the extension to be useful with the standard library as well.

Note: There’s a demo game for this exension, in the howto folder in the PunyInform distribution.

Note 2: This extension doesn’t use any objects, since a game can’t have more than 255 objects in z3 story files, and this is an important target for PunyInform. You may or may not like the non-object oriented way of handling conversation.


DMenus is a reliable classic. (Doesn’t work with Vorple, though.)


Agreed, I’ve used DMenus.h before (but at a lower scale) and it seems good. One object per topic, all stored in the same object, but conceal some topics; and when the player selects a topic you conceal it and un-conceal the next topic. If that makes sense?

1 Like

One extension you may want to consider is GXScript.h by Brendon Barnwell. It’s basically the same as phtalkoo.h or gtalk.h, bbut object oriented in the same way extensions like DMenus is.

I honestly don’t see why all conversation menu extensions don’t work like this, unless you’re targeting retro platforms, in which case this isn’t a good idea.

One thing I will say about GXScript is that it prints the conversation trees in a separate window, which is probably very visually appealing, but as with anything else that prints to a separate window (aside from the status line, as well as the help/hint menus), it makes it unreadable by screen readers.