Speed, speed, speed

Lately I spend a lot of my time wrestling with performance issues under Glulx.

This is partly because most of what I’m working on is, in one way or another, a test of the big conversation library I have in progress, and this is necessarily very code-heavy. But if I’m wrestling with it, that’s not good, because it means other authors using it are likely going to have to do the same — and they may have less patience with the problem, or just find that the whole thing is too irritating. For small projects, the system works fine, but for Alabaster (ca. 250 quips now) even after a fair amount of work, there is a 1-3 second delay on a lot of the moves. That is Just Not Okay.

There are three points of attack here, as I understand the problem:

Optimizing Inform so that it compiles code that will run faster. Several things have come out of my (or other people’s) performance problems in the past — Graham has sped up pathfinding and handling of large “Instead…” type rulebooks, and our recent conversations might conceivably lead to speeding up the performance of object-based rulebooks (which are one of the key pieces of the conversation library, since every piece of conversation has to be consulted to see whether it can be said at the moment).

Optimizing my own source. I’m working on that: finding more ways to cache needed information, minimize the scope of loops, etc. (And, since I mean this to be a released extension down the road, figuring out how to give authors of other work help optimizing their stuff, where those optimizing tricks cannot be folded into the core library but require some per-game customization.)

Speeding up interpreters so that any speed problems that remain are minimized for the end-user. Here Git seems to have a clear advantage over its competitors, but I haven’t had luck so far building it for OS X. (That might be because I have no ****ing idea what I’m doing. I am not exactly an old hand with gcc.) Has anyone else had luck with this? Is there an already-compiled OS X Git (using the latest, January 2008 version of the code) out there that I just don’t know about?

It looks as though Git might be what’s under the hood in Spatterlight (at least, Spatterlight seems to play faster than Zoom, at least a bit) — but if I actually open the Spatterlight package, it doesn’t list Git, only Glulxe. And I don’t see anywhere within the Spatterlight application to find out what version of interpreter it’s using. Which I guess doesn’t matter too much if it does, in fact, play faster… but this is all kind of mystifying.

Alabaster Interim Status Report (Release 18)

I am still working on Alabaster’s edited beta; in case anyone is interested, I’ve posted the latest build (18), but this should be regarded as just an interim thing while I continue to work on a release candidate that can be sent around to testers.

Continue reading “Alabaster Interim Status Report (Release 18)”

Alabaster Processing

So general submissions for Alabaster are closed, and I’m working on incorporating the last changes that I was sent. Thanks everyone who participated — this has been really useful and interesting, and I have hopes that the end product will be interesting as well.

My plan at this point is to

— work on the file myself a while (debugging, optimizing the code, tying off some conversational loose ends that no one wrote any conversation for)

— beta-test the game (I usually hold closed beta tests, but since this has been an open project an open beta seems more appropriate as well); this will also be an opportunity for collaborators to comment on how their contributions were interpreted or add any finishing touches that they wanted to add

— upload to the archive and add IFDB info, at which point the game will be considered officially released.

What follows here is mostly a postmortem on the experiment, with some further thoughts.

Continue reading “Alabaster Processing”

Alabaster, Release 13

Release 13 is now up, and the conversation graph is getting fairly complex. There’s still lots of room for contribution, though — small contributions fleshing out the story are just as welcome as more ambitious ones.

The thing is starting to run with more delay than I would like. I have some ideas about how to streamline this, but can’t do so this afternoon. (Some of it has to do with the collaborator interface itself, but I will want to optimize any pieces that will wind up in the final game.)

Alabaster, Release 10

Thanks to Eric Eve, I’ve worked out the hanging bug in Release 9 (sorry about that!). Release 10 should be stouter.

It also comes with new dialogue and a couple of new features:

  • New “player mode” allows collaborators to try the game without the collaboration interface popping up. Try PLAYER MODE ON to activate this, and PLAYER MODE OFF to turn it off again.
  • THINK will remind the player about what he has already learned on this play-through.
  • The tag “[if immediately]…[otherwise]…[end if]” can be used to mark a variation in dialogue depending on whether a quip immediately follows its prerequisite quip, or comes in sometime later. (See the “that the safe haven seems too far away to reach tonight” quip for what this looks like in practice. This is just an extra; if it seems confusing, ignore it.)