Creating a *very specific* riddle game with a "linear map".

Thank you. Not only do I agree, but you’ve given me two great leads. I will investigate “The Grand Quest” and “Gleaming the Verb” immediately.

Yes, that’s what I would like to do. I still believe Inform can help me here, but I’ve yet to see any game (or code) that’s remotely similar (of course, I haven’t looked into your two previous references… yet). I’m looking for precicsely what you term “appropriate conditions” and “the exact syntax”! Those are not mere details… they are the core of what I’m after! :slight_smile:

I can’t just have people automatically transporting from room to room. It has to be conditional:

  • Room1. there’s a bunch of crap in it (objects, scenery, a dude who talks, etc.). describe it all to the player (including the riddle that needs to be solved). ask the player: who stole the dude’s cheese?

  • await user input

  • if correct (and i know Inform is pretty flexible with user-input, as i can code synonyms for the correct answer) then move user to Room2

  • else, do nothing (user stays where he is. frustrated.)

  • repeat until bored

I know Inform wasn’t designed to handle this, but there’s nothing (so far) which tells me it can’t handle it. To me, it seems simple… but I’m no Inform pro, that’s why I posted it here.

This, I think, will compile, and may be starting point for what you want to do.
(I’m sure the code is much less elegant than it could be …)

[code]Include Basic Screen Effects by Emily Short.

A room has a list of indexed text called facit.

The successor is a direction.
The predecessor is a direction.
The successor has opposite predecessor.

#1 is a room. “Fatumeh has just eaten her fill of kiwifruits. However, she still has 15 fruits left and wants to divide them equally among her 3 brothers (Tom, Dick, and Harry). How many kiwifruits will Harry get from her?” The facit of #1 is {“5”}.

#2 is a room. #2 is successor of #1. “Lincoln’s Gettysburg Address begins:[line break][bold type]‘Four ___ and seven years ago’[roman type].[paragraph break][italic type](Please type the missing word at the prompt below.)[roman type]”. The facit of #2 is {“score”}.

#3 is a room. #3 is successor of #2. “How many kiwifruits will Tom have?” The facit of #3 is {“5”}.

Last after reading a command:
let L be a list of indexed text;
add the player’s command in lower case to L;
if L is the facit of the location:
stop the action.

To reinforce:
say “[one of]Correct.[or]Quite right.[or]Good.[or]Exactly.[or]That’s right.[in random order]”;
try going successor.

To extinguish:
say “The correct answer is:[line break][facit][paragraph break][italic type](Press any key to continue)[roman type][paragraph break]”;
wait for any key;
try going successor.

To say facit:
say the facit of location.

Instead of going nowhere from a room:
say “[paragraph break]We’re finished.”;
stop game abruptly.

This might not be the most original idea, but in Room #1 I would put a door that gets unlocked when the player’s score => 1. Set the door in Room 2 to unlock when score >= 2, and so on. Then, give the player a point for solving each room’s puzzle. When they solve a puzzle the door will open, and they can always move backwards.

This is the sort of thing I was thinking of. I’ve taken George’s code and changed it so that when you give the correct answer it automatically moves you to the next room:

[code]The Manipularium is a room. “Here you manipulate. There is a locked door to the north.” The Pullarium is a room. “Here you pull. There is a locked door to the north.” The Contactorium is a room. “Here you contact. There is a locked door to the north.”

Instead of going, say “The only exit is the locked door to the north, which is locked.”

The block answering rule is not listed in the report answering it that rulebook.

Instead of answering yourself that it when in The Manipularium:
if the topic understood matches “manipulate”:
say “Correct!”;
say “The door to north unlocks, and you go through it. As you do it vanishes behind you.”;
move the player to the Pullarium;
say “Gesundheit!”

Instead of answering yourself that it when in The Pullarium:
if the topic understood matches “pull”:
say “Correct!”;
say “The door to north unlocks, and you go through it. As you do it vanishes behind you.”;
move the player to the Contactorium;
say “Gesundheit!”

Instead of answering yourself that it when in The Contactorium:
if the topic understood matches “contact”:
say “Correct!”;
say “The door to north unlocks, and you go through it. Outside is sweet freedom!”;
end the game in victory;
say “Gesundheit!”

test me with “n / e / s / u / say xyzzy / say Manipulate / u / say pull / u / u / say contact”[/code]

Now there are several awful things about this, most prominently that the door is mentioned in the description but you can’t do anything with it. If you’re going to use this sort of thing you need to implement a door-object that the player can interact with, even if they can’t open it and use it to go north. Maybe it’d work best to implement it as a locked (and impossible to unlock) door; but anyway, if you want to automatically move the player to a room, “Move the player to the Pullarium” works.

You probably also want some different ways of parsing the answer; I have no particular ideas here.

Also, there’s no reason to be snippy with the people who are talking about CYOAs. They were being perfectly polite and trying to help; which I suppose is “trying something,” but it’s not like anyone was trying to put one over on you.

Is there a reason why just using “now the player is in Room 2” wouldn’t be optimal?

I also still think that having the player tell the answer to someone is the easiest and most intuitive interface. I mean, it’s 3 (edit: I can count) lines:

After telling the Sphinx about "[man]": say "Correct!"; now the player is in Room 2.

Yes, I understand that the plot is PREDETERMINED. The exact playthrough, however, is not (which is what distinguishes any interactive work from a non-interactive one!), and “you either pass, or fail” is a branch in the gameplay tree, even if it is not a particularly divergent one, plotwise.

Perhaps the word “choice” is the problem here, since it implies moral agency or something. It does sound a bit silly to say “The student chose to answer that 2+2=4,” but we get that in the phrase “multiple choice exam” as well.

Ah, well, that does sound a bit different than what you were talking about before. But I’m confused: does the examining of the room happen over several moves, or is it all in a static printed paragraph? I can definitely understand why you want a more robust world model if the former, but your description earlier (and “ONE move to make”) sound more like the latter.

I want to clarify, by the way, that my intent is not to malign your project, either in general or by comparing it to CYOA (which you may have heard negative rhetoric about around here). I just thought that it sounds structurally similar to CYOA, and therefore that extensions like Adventure Book would be a good jumping-off point for your code.

Well, in The Grand Quest, they were (mostly) object-manipulation puzzles (requiring a model world), not puzzles where you proceed by saying the right phrase. From the example that Tigger31337 gave in hir first post (“The keypad display reads “2+2=”. What number do you punch on the keypad in order to unlock the door?”), this game would be a lot more call-and-response.

And I think it’s interesting that you list Gleaming the Verb, since one could argue (and several did, in their Comp reviews) that it wasn’t “really IF.” Sure, the magic words that you said to proceed looked like IF commands, in that they took the form of the verb and an object, but there was no indication that you were “actually” performing that action on the object – in fact, one of the verbs was not even one that could sensibly have applied to the object.
I quite agree that Gleaming the Cube would be a good precedent for Tigger31337 to take a look at, at any rate.

So it sounds like you (mattw) are categorizing CYOA based on whether the paths are explicitly demarcated, and I am categorizing CYOA based on whether or not the world is modeled beyond having a look-up for what the current right answer is. Arguably, of course, my definition has a fuzzy boundary (imagine a puzzle-room in which you simply have to push a rock away from the door to proceed. Is it IF because you are affecting the model world by model-pushing a model rock away from a model door, or can we treat it as CYOA and just check to see if the player typed the magic phrase “push rock”?), but I think we’ve already seen that boundary poked at from both sides in CYOA-with-a-lot-of-flags and IF-with-menu-based-conversation. Anyway, it’s always interesting to see what different people think of as the one true defining characteristic of any given category (especially when that category does have multiple common characteristics, as this one clearly does). On that note, I’d be curious as to what you think the exact opposite of CYOA is. I say “a televised production of a Jacobean tragedy.” :stuck_out_tongue:

True – and that was something I kind of had in mind – but I don’t think anyone argued that it was CYOA. People tended to say things more like “It’s a series of word puzzles.”

Yeah, I definitely think of explicitly demarcated multiple choices as defining the CYOA. I don’t suppose I have any argument for that, just a sense that that’s what people usually mean. And I’d think of keyword-based IF as another raid on the boundary; there are a finite number of keywords you can type, but there may be a lot of them, and they map to interactions with the model world in some way. (Though all, and I think I mean both, of the keyword-based IFs I’ve played allow you to go outside the keyword anyway.)

I wonder if it makes a difference to our sense of what CYOA is that I grew up with the Edward Packard books. (And the R.A. Montgomery ones, but Packard’s were just better.) Did you read the books at all?

First of all, there’s lots of good stuff coming in, so thanks for that.

I still see a persistence to categorize my work as (or compare it to) CYOA. Rest assured, you are doing CYOA an injustice if my simple little linear plot is lumped into that category. When (most) people use “CYOA” they are doing so in a context that does not (normally) include my work - on any level of description.

That being said (and I hope we can put this CYOA thread behind us now) I’m making great progress with the code. I’m working off George’s original post (with mods by others, notably matt w.). I’ve removed the door and all references to it. For now, the user is simply transported from room to room. Since the game has no plot and disjointed scenery from one room to the next (on purpose), I didn’t want the player physicaly moving through space (i.e. walking) to get from one level to the next. I thought it ruined the surrealism.

Everything works, and the player movement happens automatically upon producing the correct answer. The only thing I’m now stuck on, is this:

I find Inform to be a little TOO lenient with what it considers a correct response.

In one room, the player hears a piece of classical music. I’ve coded appropriate responses to be “Vivaldi”, “Antonio Vivaldi”, and “Antonio Lucio Vivaldi”. Inform is great for ignoring case (so things like “vivaldi” or “antonio vivaldi” are also accepted) but I also find things like “Vivaldiii” or “Vivaldinorium” or “Vivaldiopolous” getting through.

Now, I’m all for 16th century Greek composers, but “Vivaldiopolous” wasn’t one of 'em. And he certainly isn’t the correct answer to pass my level. Yet the player does. I thought this wouldn’t be a serious problem (hell, if you know the answer to be “Vivaldi”, and you type “Vivaldikicksass”… fine, I’ll give it to you!) but the problem is unacceptable when it comes to some of my “cypher” rooms. Occasionally, I’ve got a room with a block of cyphertext that needs to be decrypted. Here, if the correct answer is “31337” and you type “31337241” then I do NOT want you to pass. (Yet the player does).

The mechanism I’m using to parse the correct answer is via the if the topic understood matches “xxx”. I’ve read that I can use “is identical to” or “is identical with”, instead of “matches”, but that still doesn’t work.

Any tips on how to make Inform match exactly a string of text from the user? Perhaps using the “topic understood” mechanism isn’t the most flexible, here.

Thanks, again, in advance.

Have you tried “exactly matches”? Assuming you’re using indexed text (the distinctions between indexed text and “topics” are not exactly clear to me, other than the fact that apparently “topics” can only be checked against player inputs), Chapter 19.5, “Matching and Exactly Matching” may be what you’re looking for.

Probably not. I think I read a few CYOA-type books growing up, but they were pretty unmemorable.

An interesting thing about that edge case of keyword-based IF is that in many such games, you can take actions that are not keyword-based, but they’re not necessary to win. A totally parser-free keyword-based game, however, could have the same basic code structure as a work of CYOA – if the only verb is “use” (which is sort of a loose translation of “click”), the options for any given scene narrow rapidly.

Anyway, I’ll certainly cede the point that my internal taxonomy is or could be inconsistent with the rest of the community’s. The original point I was trying to make in this thread was that I was surprised by Tigger31337’s assertion that hir game had no branching, which seemed like an absurd stance to take: linear plot is not the same thing as linear interaction/code. And that Ron Newcomb’s comment was really not that much of a stretch.

No probs. BTW it doesn’t smell right because it’s not very Inform-y I guess. In the MUDs I have coded in (like LambdaMOO) the game has no concept of north, south or other cardinal directions. Any exit is just a set of things you can type that take you from one room to another, the names of which are defined as you add them from room to room. Which describes your problem exactly; so that’s why my brain went there. I don’t think there needs to be any conflict between the answers for different rooms, because the directions would only be in effect where you specifically defined them room by room. But I can see why you’d want to try another way. For one thing you’d probably have to change the standard ‘You can’t go that way.’ responses and there might be some other quirky-sounding comebacks.


Almost. In the end, the syntax that worked for me was:

if the topic understood exactly matches the text "Einstein":

…which is odd, since I didn’t have to include “the text” for my previous attempt of:

if the topic understood matches "Einstein":

Both commands work. But if you want to get around Inform’s default “lenient matching” scheme, then “exactly matches the text” will do the trick.

I hope that helps others.

It’s hardly surprising for an author to claim that his work is not a CYOA… especially when it isn’t. If you had read my original Post #1 (and, it seems like you haven’t… I encourage you to do so, carefully) then you will see that under no description is mine a work of CYOA. To repeat, if you believe that this type of a riddle-game is a CYOA, then you are most certainly operating with a different definition of CYOA than the rest of the community. I appreciate your persistence to continue to categorize my work as such, but you are still mistaken.

I see what you’re doing here. You have made the subtle move of shifting the label of CYOA from my game to the actual code itself. That is a totally arbitrary move which does not help your original argument one iota. Ron’s original label of CYOA was applied to my GAME, not the code. While it’s true that my (and almost every other) game uses if/then conditionals, that does not make it a CYOA adventure game. By your definition, Microsoft Word would be a CYOA because I get to “choose” whether or not I save the document.

I have stated earlier that my game cannot be any further from the CYOA genre. I’m sorry if I’ve disappointed you in some way… perhaps you can use your obvious passion for CYOA to try and convince the next fellow that his game is most certainly a CYOA. Know that your efforts to do so on me are wasted, because I know perfectly well that you are mistaken.

Actually, Ron’s comments were a stretch and (not to speak for Ron) but I think he’s actually understood, agreed, and moved on (since he has stopped trying to apply the “CYOA” label to my work).

I’m embarrassed to have to provide this, but:

  • CYOA names a very particular style of literature/game/IF/etc. The defining factor is that the player gets to alter the plot/outcome in a way that no two readings (or playings, etc.) are necessarily alike. For example, I can play a game once and have the protaganist killed before saving the queen. I can play the SAME game again, but this time make different CHOICES, and have the protaganist ride off into the sunset with the queen. I play it a third time, and I magically turn into a heap of dingo’s kidneys.

  • Contrast that with my game: You’re in a room. You are presented a static description (the damn room is the same EVERY TIME YOU PLAY IT!) You have exactly ONE move to make: solve the riddle. If you do, you proceed to the next room (to face another unique but static room). If you fail, you STAY EXACTLY WHERE YOU ARE.

The whole notion of “branching” was not one that I introduced to this thread. My game (at the level of the GAME) has nothing whatever to do with CYOA nor branching! That was my original (and only) point of debate. For anyone to think otherwise shows how little they know of the CYOA genre. Now, somewhere along the way, the argument has shifted such that my code would be considered CYOA. I still think that’s a terrible description, but I do not argue that if/then statements perform a sort of branching. But then again, so does every other computational algorithm. Describing a piece of software as CYOA because it “internally performs choice-making” is a weak argument and adds NOTHING to the higher-level description of the software.

Please, can we stop throwing around the term CYOA now? Give it to those who actually deserve it… not to my humble little riddle-solving quiz game.

  • Tigger31337

Okay dude — it’s not a CYOA. I can see both sides of the argument, but it doesn’t seem worth going to the wall over. If you don’t want to call it that then I see no reason why you need to be forced to call it that.

Good luck with your plan. 8)


Well, would you call it that?

Chill out, dude. This discussion isn’t a contest and nobody is trying to beat you. tove is working with a different definition of CYOA than you, and than me, but there’s no reason to jump down anyone’s throat about it, and the definition of CYOA is more fluid than you think. For instance…

Actually, if you’ll look at the one game that’s generally described as a CYOA in this year’s IFcomp, you’ll notice that

the player has almost no power to alter the plot at all, or even the events that occur and the order they occur in.

My definition of CYOA is that it has multiple-choice gameplay (which is why your game doesn’t sound like CYOA to me). tove’s definition, if I’ve got it right, is that it doesn’t have a parser or underlying world model (which doesn’t look like it’s true for your game, anyway, since it sounds like you can examine objects in the rules). Yours is that the player can affect the plot/outcome. I’m not sure which of these definitions would get the most agreement if we took a poll, but the very fact that there are different definitions means that none of us should be too dogmatic that we have the One True Meaning of CYOA.

I have always thought that the dividing lines between media are not as sharp as is generally perceived, so I don’t really feel the need to label one interpretation as correct and the other as incorrect in order to be comfortable with the situation. Binary narrative choices in which one fork is quickly a dead end or a loop are still technically choices, but on the other hand they are a type of choice that doesn’t create an alternate branch of any significance to the reader. On an implementation level that doesn’t sound like it should make much difference, but on the level of reader expectation CYOA seems off the mark, so I can see why you’d want to avoid the term. How do I choose which set of factors to consider supreme in classification, implementation or reader expectation? Especially when I’d rather not ignore half the data just for the sake of coming to a conclusion?

In other words, I don’t actually need to know. 87


I’m chilled. I know this isn’t a contest, and nobody’s trying to beat me. All I did was correct someone when he misused a term.

Now, he got very defensive, and insisted that he was right, and I was wrong. I merely corrected him again (and those who agreed with him). You may interpret my postings as you wish, but the fact stands that CYOA in an agreed-upon term and you simply can’t reshape definitions in cases where you see fit.

Well I’m glad you agree to at least that. In which case, why am I the only one correcting tove and Ron if you (apparently) agree that their definition differs from the community?

You’re missing the point. If we dig deep, we may find the oddball case here and there of something labelled (mis-labelled, I would argue) a CYOA. But my point is that MY game is not a CYOA. If you think otherwise, then I challenge you to publicly declare that, “yes, on the description Tigger gave in his Post #1, I would have to say he is building a CYOA game”.

If it doesn’t sound like CYOA to you, then why the hell are you giving me such a hard time when I am agreeing with you?! I have been saying the same thing all along: my game is NOT a CYOA! It’s really not that hard an argument to follow.

I’m truly at a loss, here.

No, in my game you can NOT affect the plot/outcome.
Maybe it’s me. I thought I was explaining such a simple game in simple terms, giving PLENTY of examples along the way. All I can say here is “re-read my posts”.

If it helps, think of my rooms as “read-only”. Yes, some rooms have objects, characters, and even a bit of dialogue. But there is not one random element in the game. Nor can you get anything to interact with each other (though, even if you did, that wouldn’t make it a CYOA). I would argue there is no plot, but if you say there is, I think we would both agree that it’s a fixed, determined, and unwavering plot. Please, for the love of all things sacred, tell me how THAT description I just gave is anything remotely similar to a CYOA. There is no “Choose” and there is no “Adventure”. All you’ve got is a “Your Own”. :confused:

I completely disagree. I think, deep down, we all know what a CYOA is, even if we can’t come up with a discreet set of rules which define CYOA. CYOA is a category and, like all categories, there are some items which might not fit neatly into said category. But also keep in mind that some items are EASILY placed into or outside the category. If you (or anyone) still think my game fits in the category of a CYOA, well then not only are you mistaken (sorry if that offends, but I just don’t know a nicer way of saying it) but also I am VERY curious to hear your definition of a game that would NOT be considered a CYOA.

I think the best thing we can all do here is stop pretending that we are “defending” some mistaken definition of CYOA. There’s CYOA, and then on the other end of the spectrum is my game. I can’t, for the life of me, understand why ANYONE would persist in this silly endeavor of lumping my game in with the CYOA label.

Good luck, is all I can say to those who try.

Wow. Way to show your knowledge of the subject matter by confidently answering a simple question. (Don’t worry, you’ll get another chance to answer when I ask you further down in this post).

No. They most certainly are not. You are performing the exact same error I outlined earlier. You are confusing the description of my GAME(PLAY) with the description of the CODE. No one here (not even me) would argue that source code can not contain if/then conditionals, but the crap you just spewed about “binary narrative choices” is laughable. Nowhere in my game do I have “binary narrative choices” because nowhere in my game do I give the player choices.

Right. That’s very nice, but I asked you a question, point-blank, and you didn’t answer it.

For all the hype and hoopla, would you, Paul, categorize my game (based soley on it’s description, and/or on it’s gameplay (I’m sure you can imagine playing it)) as a CYOA? It really is a yes/no question, and not a hard one at that.

I suspect a lot of folks like to argue for the sake of arguing. Meanwhile, you know perfectly well that my game has nothing to do whatever with a CYOA. You just don’t like that I was blunt enough to correct those who thought otherwise.


0/10 for etiquette, on my part.
But 10/10 for actually being correct.

And it’d be one thing to critique my etiquette, but the sad part is watching folks critique the brute facts of the game and the definition of CYOA! I can’t believe there are still those who wish to persuade me that, on SOME level of description, my game is a CYOA!

Uhmm, close but still no.

I did answer your question with exactly my opinion on the issue, and I wasn’t talking about if/then statements. I was talking about the implementation of player choices. Your implementation of player choices resembles the implementation of player choices in CYOA more than it does IF. In CYOA the player is given simple choice points, in which they know that one of two things will happen, or one of three things will happen, like that. In IF the player is given a sandbox to play in, where the number of possible narrative choices is disguised: it isn’t immediately apparent. Achieving these two different effects for the player is a lot of the difference between a CYOA design system and an IF design system. Your idea is closer to CYOA on that level. However, on the level of 'what do people expect to happen when they play a CYOA (extensive branching) it obviously is not a CYOA. I know you don’t want to accept that as an answer, but it’s reality as I see it. I believe some things genuinely don’t fit squarely into the appointed categories – these categories are man-made, I know you realise that: but do you believe they’re perfect? No overlap whatsoever? It isn’t a yes/no question. And your idea, in my opinion, is one of those things that can’t be squarely put in either camp. So what am I supposed to do, invent another opinion other than what I believe? You’ll have to accept it or not accept it as you see fit but that’s my answer.

BTW I was trying to help you.