Sit, Ubu, Sit! Good Dog

Note to Macintosh developer community:

The days of the .sit file have passed.

StuffIt Expander isn’t even included by default anymore on new Mac OS X 10.4 “Tiger” systems. You have to download it separately.

Now, I will admit, this is easier than it was even just a year or two ago. Allume Systems (née Aladdin Systems) used to make it incredibly difficult on their Web site to even navigate to the free Expander download. And the download was in fact not Expander, but rather StuffIt “Standard,” which included several additional shareware products most people didn’t want. The philosophy seemed to be, “If we just piss off our users enough, maybe they’ll buy something from us!” Ugh.

When I just tried to download StuffIt Expander 10, however, I was able to get to the download in two clicks, and the resulting installation was Expander alone. So that has improved.

But you’re still requiring your users to find and download a third-party application just to get to your product.

If your product is Mac OS X 10.3 “Panther” and up, the solution is easy: use the operating system’s built-in “Create Archive” contextual menu in the Finder to build a .zip archive of the files you want.

Now, if you’d used the command-line zip utility on Mac OS X 10.2 “Jaguar” or earlier, you would’ve found that it ignored Mac-only filesystem attributes like resource forks. “Create Archive” is smarter than that. If you double-click such an archive in the Finder, it will extract the archive contents, resource forks and all.

The downside? “Create Archive” uses a custom directory layout (presumably in order to organize the extra bits) which will look strange if you attempt to open that archive with a more traditional command-line zip utility, even the zip utility at /usr/bin/unzip on that same OS X 10.4 “Tiger” box where you made the archive in the first place! (Not to mention the zip utility on 10.2 and earlier.)

This means that these .zip files, which by their suffix look nice ‘n’ cross-platform, really aren’t. They’re still primarily for delivering content to Mac OS X users. Your sole benefit is that the archive will be double-clickable on 10.3 and higher, without additional downloads.

If you need to support Mac OS X 10.2, well…I hear StuffIt Expander is easier to download than it used to be. Oops! You have to go back to StuffIt “Standard” 8.0.2 to get Mac OS X 10.2 support. It looks like they require you to join their mailing list just to download the damn thing. Tough luck….

My advice? Make a .dmg file.

A TADS TADS TADS TADS World

The TADS interpreter scene on Mac OS X is a bit like the browser scene. There are more of them than you’d expect for a minority platform, and they embody different philosophical approaches.

The saying goes: “Cheap, fast, or good: pick two.” I tried “perfect” with my MacTADS project and wound up never finishing it at all, so it’s no surprise that the authors of the following interpreters made a different set of compromises in order to get their applications out the door.

(The observations below are more about the UI than a detailed review of gameplay.)

QTads
First, Nikos Chantziaras wrote FrobTADS, a command-line port of TADS that replaces the old, crufty port mentioned in this post and used in Uli Kusterer’s TADS Workbench for Macintosh.

Second, he built a GUI TADS interpreter on top of that, called QTads. As ANSI C and POSIX are to FrobTADS, Trolltech‘s Qt library is to QTads: if you support those APIs, FrobTADS and QTads respectively can be built for your platform.

This approach led to a full-featured interpreter for the Mac platform without needing someone to commit full-time to it. QTads even has some niceties not in other Mac interpreters, such as a font/color “preview” panel and theme sets.

The downside is that QTads is a Mac application the same way Eclipse is a Mac application. Colorful, but not exactly native-looking:

QTads Game Menu Screenshot

Huh, an Exit menu item? Never fear, there’s still a regular Quit menu item under the Application menu, but this goes to show we’re not in Cocoa anymore.

As another example, have a look at these two lower right-hand corners of windows:

QTads Lower Right-Hand Window Corner NetNewsWire Lower Right-Hand Window Corner
QTads NetNewsWire

QTads has an ugly black outline around its main scroll view, and its window grow box is half the size of a native Macintosh window grow box. NetNewsWire’s version is provided for comparison.

Finally, if you resize the window, you’ll notice some flickering. QTads eschews OS X’s double-buffering, and instead erases and redraws the edges of its window right before your eyes.

Some of this might be fixable with more work on Qt, but some of it is a deliberate, un-Mac-like style that comes with the territory.

Cugel
Cugel’s author made a different set of compromises. Native? Check. Full-featured user interface? Well, not really. For example, there’s no status bar area at the bottom for a “more” prompt. Such a bar doesn’t come native with the Cocoa scroll view, which is why my in-progress Neutrino main window doesn’t have one yet, either.

But what you get instead is a “Unified Interactive Fiction Player.” It can play not only TADS games, but also Hugo games, Alan games, Glulxe-based games (supported by Inform), and others.

It’s actually pretty cool to look in the Cugel package and see the individual interpreter utilities for all these languages.

Ben Hines MaxTADS OS X port
Ben Hines made a third set of compromises. My impression is that in 2002, he saw that there was already a perfectly good OS 9 TADS interpreter, Andrew Plotkin’s MaxTADS. He also saw that Apple provided a quick way to port such Toolbox-based code to OS X, the Carbon APIs.

So he “ported” MaxTADS to Carbon, and by “ported” I mean that he made the fewest changes possible to the codebase and resources so it would build and run as a Carbon application on 9 and X. The UI remained entirely unchanged, and it looks more and more anomalous on subsequent versions of OS X. For example:

MaxTADS Carbon Port UI

Yes, that’s a System 7-style textbox you see!

Here’s another issue. Two quit menus:

MaxTADS Carbon Port Menu

The Cmd-Q keystroke shortcut does nothing, by the way. You have to select the menu item by mouse.

The upside of all the hurried work? This was the very first native OS X TADS GUI-based interpreter. The other two interpreters mentioned above were released two years or more after this MaxTADS port.

..Than a Speeding Neutrino

I’ve talked about my travails using Subversion and getting unit testing set up. I was mysteriously vague about what it was all for…

…Until now. (Cue ominous music!)

It’s for an application called Neutrino, which will allow you to do something on a new Mac 1-2 years from now that you otherwise wouldn’t be able to do.

Word by Word
Neutrino is a TADS multimedia interpreter written in Cocoa using Xcode. Let’s break that down:

TADS: “Text Adventure Development System,” a special-purpose programming language, library, and virtual machine for both writing and playing interactive fiction a.k.a. text adventure games. Wikipedia has some history on it.

multimedia: When TADS was first introduced, it was strictly T, for textual. Its author, Michael Roberts, eventually decided to add some multimedia capabilities to it. He called it HTML-TADS, because the way to add these elements was via a simplified and customized form of HTML markup. There are only two interpreters that can fully display such content, the TADS interpreter for Windows that Michael Roberts himself wrote, and HyperTADS for the Mac, by Iain Merrick.

interpreter: TADS source code is not compiled to native CPU instructions, nor does it use specific operating system APIs. Instead, it’s compiled to be played in its own virtual machine maintained by a platform-specific interpreter, like Java source is compiled to run on a Java virtual machine.

Cocoa/Xcode: Because Neutrino is written using these technologies, I will be able to release a “universal binary” version of Neutrino, that will work on both PowerPC Macintoshes, and the Intel Macintoshes that will be released over the next several years. (Carbon/Xcode would be another possibility.)

History
For TADS’ early history, the sole Macintosh interpreter was also maintained by Michael Roberts. It used the early Toolbox TextEdit APIs, though, so it was limited to 32K of text scrollback. Plus, it didn’t display any styled text at all.

Once TADS went open source, Andrew Plotkin wrote a new interpreter for it, called MaxTADS. It had all the bells and whistles and matched in both style and name his interpreter for Z-code games, MaxZip.

When HTML-TADS arrived, HyperTADS was written to handle it, since MaxTADS remained text-only.

This all happened before OS X was released.

Current Interpreters
Today, there are three native TADS interpreters that I know of for OS X. Ben Hines did a quick-and-dirty Carbonization of MaxTADS in 2002. Recently, the more substantial ports QTads and Cugel have been released, and are under active development. I do a more thorough review of these interpreters (or at least of their UI) in this post.

So the native interpreters won’t display multimedia game content, and the one Mac multimedia interpreter is non-native and won’t run on Intel Macs.

Answer to the Riddle
If you buy a new Mac 1-2 years from now, and you want to play HTML-TADS games like Six Stories or Arrival or Exhibition to their fullest, you will be out of luck, unless I get my ass in gear and finish Neutrino.

Oh, yeah, one last note: it’s not finished yet. In fact, it’s probably about 10-25% done. But here’s a screenshot:

Neutrino Screenshot