I’d venture it’s a good name - I didn’t even realize it wasn’t an actual Infocom spell until just now.
From what I guessed, it comes from the Vorpal sword mentionned in the poem Jabberwocky (Lewis Carroll).
The hints that led me to this conclusion:
- The previous Vorple site had pictures of the white rabbit and the wabe.
- To check if running in Vorple instead of a standard interpreter, “Callooh!” is written in an external file, and Vorple replies by writing “Callay!”.
Now, why this name was chosen, and why “Vorple” and not “Vorpal”, we’ll have to wait an official answer.
The reason is somewhat convoluted and uninteresting, I’m afraid. The early proof-of-concept demos used Google’s Closure library which has “goog” as its main namespace. The custom “Vorpal” methods used similarly the “vorp” namespace. Therefore because goog --> Google, then vorp --> Vorple.
Naming tools and interpreters after Infocom spells was already in decline, and I didn’t want to tie a “future-oriented” thing too much to the past.
So I’ve gotten Vorple up and running and tried a few examples. There’s one piece of functionality I don’t really understand: whenever I click on the “>” prompt (any example really), I get a hover menu containing a few commands (presumably some of my commands, but oddly enough not the latest). What’s happening there? Can I change that behavior? The Vorple source itself yields no obvious clue.
I think that’s the browser’s autocomplete feature that suggests past input when you focus on the input field. You can disable it by editing the Templates/Vorple/(manifest).txt file and changing line 69 to:
<form id="lineinput" autocomplete="off">
That’s interesting! Is there documentation that covers this and similar functionality?
I am not sure if this is the right forum to ask this question. But is it possible to import data from an excel file into a table in inform 7 using the latest version of vorple?
It should be possible, but quite a complex task. Roughly the process would be:
- Parse the Excel file, possibly with something like https://github.com/SheetJS/js-xlsx . If you can use e.g. CSV files (exported from Excel) instead, that would make it somewhat simpler.
- Save the file and read it from Inform as per the same chapter, 23.13.
Files are saved into a virtual filesystem so you’ll have to operate it using methods documented here: https://emscripten.org/docs/api_reference/Filesystem-API.html#id2
Another unrelated question.
I am trying to add a pre-test and post-test to my game. Is there a way to block the user from playing the game until they have completed the pre-test?
PS: I am planning on using another webpage containing multiple choice questions for my pretest.
The easy solution is to just have the link to the game at the end of the test. The second easiest is to have the game ask for a password at the start and give the password when the player has completed the test. Something like this:
Password accepted is a truth state that varies. Password accepted is false. When play begins: say "Please give the password." After reading a command when password accepted is false: if the player's command matches "swordfish": say "Password correct!"; now password accepted is true; otherwise: say "Incorrect password, please complete the pre-test to get the password."; reject the player's command.
This was really helpful. Thanks so much.
Do we now have access to game transcripts in vorple?
Also, is there an instance id associated with a particular instance of a game/story? As in, when a user attempts playing a game, is there a game session id that is created, which differentiates this attempt from the other attempts of the user at this game? If yes, how to access this value?
Transcripts are not yet supported. What happens when the player tries starting a transcript is described in this issue on Github.
when play begins rule, or a
Vorple interface setup rule depending whether you want one unique ID per page reload instead of play.
So if I use a rule in “when play begins”, to generate an ID for that instance of the game, would it work even if a player saves and restores the game later. As in, in case the user restores a previously saved game, would the game still have the same ID?
Also, where is the game saved when a user saves a game?
If you store the ID in a Inform variable, then yes, restoring a game will also restore the game’s ID. Something like the following; I haven’t tested but it should show the basic idea.
Obviously, if you only need the ID on the story’s side, then you don’t need JS, you could do it in Inform.
Saved games are stored in indexed DB (data stored in a local database). You can see where by using the developer tools of your browser. If I recall correctly, it’s in the entry
[checksum] is a unique ID based on your story file.
In some initial testing, it seems using “hide the prompt” in “When play begins”, and then using Vorple hyperlinks “without showing the command” works fine in this manner. Is it feasible to handle a whole game this way and never unhide the prompt, or is there some technical downside to doing so?
Yes, that should work just fine. The documentation just tries to say that unless there’s something set up to continue the game instead of player typing commands on the parser, there’s no way for Inform to unhide the prompt on its own. But if you use only hyperlinks and want to disable the prompt completely then it’s not a problem.
A question about Vorple.
I am running a sort of ARG that focuses around an Interactive Fiction on my website. However, the players are bypassing a lot by simply downloading the zblorb file, reverse engineering it, and then just reading descriptions of things, and seeing if anything has changed. The game gets updated live on the website through an automated build process I set up.
However, I am trying to prevent my players from cracking the zblorb file. I wanted to move it to the server side, but that would mean I can’t use vorple, which is great. I was thinking of trying to create a layer inside vorple or parchment to relay the message to the server for me, but not sure if that is possible or where in the code I might look.
Thoughts or suggestions greatly appreciated!
There aren’t any bulletproof ways to prevent people from digging up the story text, apart from having everything come from the server. Here’s a couple of ideas to make it at least harder:
- You can use Ajax to fetch text snippets from the server. You can look at the Scrambled Eggs and The Sum of Human Knowledge examples in the main Inform 7 extension or in Inform 6 examples directory, and combine fetching the data in the latter with replacing story content in the former (create an empty element, fetch the text from the server, fill the element with the text.)
- Take advantage of the fact that while it’s easy to extract text from the story file, it’s hard to extract and follow game logic. You could scramble or encrypt the text and unscramble/decrypt it for printing. If you use some obscure scrambling mechanism, it would be hard (but not impossible) to figure out how to reverse it based on just seeing the scrambled text.
- Add “decoy” content: Inform doesn’t do dead code elimination so anything that’s in the source text shows up in the text extracted from the story file, even if it’s never used anywhere. There’s no other downside than a small increase in the filesize. For example, if the important information is “the treasure is in the sunken pirate ship”, add a bunch of:
To say decoy1: say "The treasure is in the abandoned church." To say decoy2: say "The treasure is in the bank vault." To say decoy3: say "The treasure is under the kitchen floorboards." ....
- Same as above, but run the whole story text through a Markov generator (e.g. https://www.dcode.fr/markov-chain-text), maybe mixed together with some unrelated but similar text body, and copy-paste the results as “to say” definitions (or routines in I6) to random places in the source text. If there’s enough text it would be hard to tell which parts are real and what’s just nonsense.