Several sites that praised Sarien.net’s arrival on iPad also called these games “Point & Click” adventuregames. That is in fact incorrect, as these games were from an era before that. Interaction was done solely by the keyboard, though an optional joystick was supported. There was no mouse support for the likes of Police Quest, Leisure Suit Larry, King’s Quest or the others, and no way to point and click. Clicking wasn’t even a verb then.

Going from cursor to tap

What I did for sarien.net on the iPad was add a touch based contol scheme so you can tap anywhere on the screen and the game’s ego will try to walk there. The code for this was already present at the sarien portal that offers these games for desktop browsers when played with a mouse, and needed only a little tweaking. Double-tap was added to quickly relocate your avatar in case you are stuck or if you just want to speed up the gameplay a little, and tapping with two fingers performs a quick “look around” action.

What I also did was detect what text commands a game would actually give a response to. This is a process of listening to the possible inputs on run-time that Sierra’s original parser accepts, doing some semantic juggling and finally rendering them as buttons ready to be touched on your iOS device.

Going from text input to shiny buttons isn’t easy

Mapping these commands to buttons is the reversed process of parsing manually entered text. That latter process is relatively easy, as “open the door” would be first stripped from the word “the”, leaving “open” and “door” as commands.

A dictionary maps these to its shorthand commands “o” and “d” that for instance the Police Quest parses listens to. Finally the sentence that it requires is “o d rol” where “rol” means “rest-of-line”. What sarien.net’s code does however is more complicated, as I am only given such system commands like “o d rol” or “add shot anyword” which I need to resolve to “drink whiskey”. And that’s just the tip of the iceberg of some pretty complicated algorithms behind presenting a text-based interface as shiny buttons.

Keyboard support on the iPad I tried to present iPad users with a touch interface that is more friendly than having a keyboard presented at all time. The iPad’s glass screen is great for presenting these old games in full, and requiring the large keyboard would not do justice to these games visually (nostalgically speaking).

Still, there are situations when the touch interface has you hunting for a specific command in a similar way we all were hunting down the right text command back in the 80’s.

Therefore, I’ve added a simple keyboard button that prompts you for text input when the buttons don’t suffice. Also, you can simply touch the screen with 3 fingers or more to have the keyboard come up as well.

0

Comments

blog comments powered by Disqus