Bug of the moment 2006-12-24
I would not call this episode a bug as such (apart from the end), but it’s a curious look at dealing with untrusted input, a message that it never hurts to get across.
I have just last night upgraded the classic side of Brunnhild to Mac OS 9.2.2, enabling Classic to start under X at last (instead of just getting stuck and making its Dock icon really agitated). I decided that, since I cannot play games on Firetrack (they don’t yield the processor to the Web server), I’d copy over a couple onto Brunnhild; I chose Jazz Jackrabbit 2 demo and TheZone.
I fired up Jazz Jackrabbit 2, and started playing the first level: the laboratory level, which reminds me of a certain, cute American graduate student, whose new-found alter ego is as follows:
And this hilarous snapshot must be of her when she’s in a bad mood! (I think she’s coming after me)
(Never seen the rats do that before, good thing I have Snapz Pro set to open on a single keypress!)
I noticed two things. The level is not called “Lab Rat” or “Labratory Level” (as per the music rip on World of Game MODs) but in fact “Darn Ratz”; it’s been a while since I last played this game, and when I did, it burnt out my beloved Diamontron monitor and has been in disgrace since.
After installing Snapz Pro on the iMac to capture a screenshot of the Darn Ratz level (and it took something like five minutes just to start File Sharing on the iMac for the first time), I spotted something else – Wabbit.Cfg:
I find this odd: not only is the configuration file exposed, but it’s a Mac-line-endings plain text file associated with SimpleText. Which means that I can override the game’s maximum resolution of 640×480 like this:
And like this:
That MMX is claimed to be enabled on my PowerPC iMac, though, is not my doing.
Of course, the good folk at Orange Games/Epic/LogicWare did not anticipate this “twiddling” of mine (Mac users being dumb ’n all) and you get some bizarre results. The splash screen functions correctly at the new resolution (except with increasingly tiny “Press fire” text):
but the main menu itself displays an area of rapidly changing rubbish at the bottom of the screen, corresponding to the unexpected part of the display (above the maximum supported resolution of 640×480):
What appears to be a static area of junk is in fact a randomly changing display that keeps pace with the frame rate of the animated backdrop. On exiting Snapz Pro the game appeared to automatically engage level one and crash, but I came to realise that it was simply showing the demo, and that the crash is not caused by Snapz Pro but the fact that the game itself won’t play in an unrecognised resolution. This is all you see:
But Mac OS is cute. By default, if you don’t acknowledge a message box, it reads it out to you. Normally I’d press the reset button at this point, since the system seemed screwed, but on the third time around I left the Mac long enough for it to decide to read out a crash dialog box aloud. The game had gone down in flames (Type 2 error) and the system forgot to redraw the screen. The grey background is what shows during a resolution change before the desktop picture is adjusted for the new resolution and depth, the desktop icons are all repositioned and applications are told to redraw their windows. At this stage, no window borders are even painted.
No need to reboot – if this is all the cause is, I just need to hit OK to cancel the message, then cmd-O to relaunch the game, and then quit it safely, putting my screen back as it should be.
While I am here, here is a rat lodged in the landscape and unable to move:
Although it seemed to get itself unstuck by the time I reached it. As for that rat that jumped at me with all those teeth: I dogded and it fell right through the ground and ended up on a little pedestal of ground, trapped, unable to go anywhere and flipping back and forth like a madman (madrat):
For the record (and I know you’ll want to know), nonsense resolutions like 12345×678910 or control characters don’t work: the game goes back to a default of 640×480 which is a pity.
Posted 24th December 2006 – Comments and questions?