IF excerpting for a web page

Here’s something I came up with (hastily) last night:

eblong.com/zarf/tmp/diffdemo.html

The notional problem is this: say I want to write a blog post, talking about how I dealt with a particular IF design problem. I want to show off a piece of my game – one scene, with a few different possible playing paths.

The current options are (a) post the game itself, with a save file, plus some suggested commands to type; (b) post several transcripts; © post source code. I’m not satisfied with any of these. (a) requires effort that a casual reader might not bother with; (b) is a whole lot of text; © is a pain to understand.

This demo is a few moves from the beginning of Adventure, with three possible paths (one of which is a small variation), and extra annotations in the right column. The left column is links to flip between the paths.

Obviously this was a very simple piece of Javascript. The hard problem is writing a tool to parse several transcripts and generate this Javascript structure. :slight_smile: But, one step at a time – I’d like to know if you think this is a useful format for critical discussion of IF.

whoa! Your domain is blocked here at work, categorized as “Games”. Thankfully, parchment.toolness.com is not… :slight_smile:

My idea was that a normal transcript but with a link to parchment for each turn (or maybe each significant turn) might work well.

But then I saw your demo, and loved it.

Agreed, this looks and works great. What would be the specification for a general-purpose tool that does this?

I guess it’s just javascript code that you’d drop into your page and follow a few guidelines on how to format the text into html.

The HTML has to be precisely set up – doing it by hand isn’t practical.

As I said, I’d like to start with transcripts, which are an easily-generatable currency of all IF systems. However, inferring a branched tree structure from a set of transcripts is not a trivial problem. (In fact it’s a directed acyclic graph, not a tree.)

Once you have the graph, however, generating the HTML is pretty trivial.

For those using I7, could this be generated from the skene?

I was thinking about that, but the skein isn’t a DAG. (In my example, the commands “get keys” and “get all” are a branch, but they merge right back together – for the purpose of the example.)

Parsing transcripts and generating a skein-like tree is quite easy, so I don’t think there’s any advantage in starting with the skein itself. And I do think this tool needs to be platform-agnostic.

I think this is an excellent idea. As usual, I have a thought…

What if the left-hand side was a list of all of the future commands on path 1 (first transcript). Where there are forks, the commands would be highlighted somehow. You’d retain previous commands as well.

If the user clicks into a fork (transcript n), the list is rewritten downward with the future of transcript n. The previous commands remain the same.

I would also allow a limit, in the tooling automation, on how many previous commands are displayed.

The tool should allow any html in the right column, including images, links to external documents, etc.

David C.
www.textfyre.com

Not sure what you’re getting at. The list of future commands in the current transcript can be read from the transcript; it’s what’s in front of you. And commands in isolation don’t tell you anything about what the game experience is like. The forks are what’s interesting; that’s why I gave them descriptive labels.

Anyhow, I’ve implemented what I originally described. Well, a very simple version, anyway.

eblong.com/zarf/transmatte/

There are a couple more examples on that web page, and the Python script I used to generate them. It’s not entirely bug-free, but it’s usable. If you want to upgrade it, go nuts.