Friday, 26 February 2016

wadeclarke.com rebuilt and Time Warp extension for Inform 7

I just completed a new look renovation of my website and added an interactive fiction page while I was at it. The IF page is a simple hub of my games, tools, sites and blogs.

If you've not had a look over my creative projects before, I'd welcome your visit to my new site:

wadeclarke.com

Time Warp

In IF-dom, I am making available an Inform 7 extension called Time Warp. What it does: It puts a whole CYOA game I wrote on the Apple II+ when I was 12 or 13 into your game. Time Warp has lots of great endings like – 'YOU'VE GOT A LIFE-TIME AHEAD OF YOU...IN GAOL!' – all in the CYOA / Fighting Fantasy / Be An Interplanetary Spy vein.

It's all caps because the text was retrieved verbatim from the Apple II+ game, where all the text was all caps. Not a word, typo, punctuation or 40-character line justification has been revised.

Why would you want Time Warp in your game? Well, if it fits the aesthetic, why not? This would be a move in the tradition of Call of Duty: Black Ops, which had the whole of Zork in it as an easter egg, introduced by you interacting with an old computer in the game world. So in that case, your character was playing Zork.

I ported Time Warp to Inform 7 so I could make it an easter egg in Leadlight Gamma. I put an unlockable Apple II+ in the game's school.

Time Warp won't interfere with your game code. Just include the extension, then, at the point you want Time Warp to start, use the phrase 'run time warp'. I've put a demo online showing how you could embed it in an in-game computer prop:

wadeclarke.com/ifdemos/time_warp/

That site also has the link to the extension. You can right-click it and save as Time Warp.i7x

I'd enjoy seeing Time Warp show up as a diversion in an I7 game, or as a diversion in a bunch of games. In any case, this extension may just give you the idea for writing your own self-contained, reusable extension game. Or, if you want to write a really simple keypress CYOA by somewhat hacky means, look at the Time Warp code.

(You might be aware that I will be releasing a full-featured and non-hacky CYOA extension for Inform 7 in the not-too-distant future. The Time Warp way of doing things isn't suitable for anything robust or complex.)

Monday, 22 February 2016

Sylvia - Depression in the movies! and elsewhere

The other day I watched Christine Jeffs's 2003 film Sylvia, a biopic about poet Sylvia Plath starring Gwyneth Paltrow, for the third time in life. It's a film I like a lot and find affecting, and which I feel motivated to write about in the context of various artistic efforts seeking to convey the experience of depression, including the IF Depression Quest.

Plath took her own life in 1963. I will be talking about that, and about related and unrelated non-G-rated ideas in what follows.

Gwyneth Paltrow as Sylvia Plath

Monday, 15 February 2016

New beginning, new beshminning!


The game title A New Beginning indicates that there have been a series of beginnings. Or at the very least, one other beginning before this one.

What should the words 'The Final Cut' mean in a game title? I reckon something along these lines:

'This is the last and most definitive version of this game! The producers who got in the way of our vision and the cack-handed editors who failed to assemble the product correctly the first time we solid it to you have all been swept aside. At last we can present to you what we would have presented to you in the first place if it hadn't been for all these jerks and idiots. Also note that this is the last time we will be presenting this product to you, and we're doing it really definitively.'

But what do the words 'The Final Cut' mean in the pretty dumb-sounding title of the game -

A New Beginning: Final Cut ?

They mean: 'Hey. The game's on Steam now, and we got it working on Macs. Plus we added achievements and more localisation. PS The game is exactly the same as before.'

It's hardly Ridley Scott being denied final cut on Blade Runner then getting a chance to edit it how he wanted about ten years later.

In conclusion, all roads are imperfect, but some are dumb, and brainless use of terms like 'The Final Cut' and 'Director's Cut' in the process of glomming a few extra words onto the end of a game's title in order to flog it anew is part of the dumb road.

Monday, 8 February 2016

I7 CYOA Framework update and overview

I've started writing the documentation for my CYOA extension for Inform 7. Two secret testers enjoyed the first example game and their excitement is getting me more excited.

The extension itself needs more examples and more testing, but having written the intro and overview, I want to share them now so that folks get a comprehensive sense of how this thing works and what it can do.

As for a shipping date – when it's ready!

INTRODUCTION

CYOA Framework for Glulx enables authors to create choice-based games or hypertexts using Inform 7. A world model switch allows projects to be integrated with Inform's world model features (rooms, objects, people, etc.) or to explicitly ignore those features if they're not needed. You can use this extension to do any of the following:

  • Create a project consisting entirely of prose, choices and links (no parser) with or without a world model underneath
  • Create choice-based interludes of any kind (conversations and puzzles are typical candidates) to include in a parser-driven game
  • Create hybrid projects in which the player can switch between the parser and CYOA mode at will (tricky, but doable!)

The extension handles the drudge work of automatically attaching keypresses and/or hyperlinks to choices depending on the player's interface preferences. The resulting CYOA projects are user-friendly and portable across a wide range of devices and input methods (keyboard, virtual keyboard, mouseclick, finger tap). Users can toggle a screen reader mode to further customise the interface.

The 'CYOA' of the extension's title stands for 'Choose Your Own Adventure', referring to the popular series of late twentieth century books and their mechanic of narrative progression via discrete choices. I named the extension 'CYOA Framework...' rather than 'Choice-Based Framework...' for two reasons:

1. The extension code is already crammed with incidences of the word 'choice'. Naming its choice-based mode 'CYOA mode' and being able to use the prefix 'cyoa' made everything easier.

2. It's a more spirited name.

Throughout this documentation, 'CYOA Framework for Glulx' will be referred to as CF, and the terms 'user' and 'player' are interchangeable, as are the terms 'game' and 'project'.

OVERVIEW

A master switch (cyoa-active) determines whether a project is running in CYOA mode or parser mode at any given time. An entirely choice-based game will never leave CYOA mode. As an author, you can toggle the game mode as required and direct where the player goes during transitions. You can also give the player the power to toggle modes at will.

The base unit of the CF project is the node.

A node generally consists of some prose describing the current situation or location, followed by a list of choices. Choices can also appear in the prose section of the node. (Graphics can be used as choices, too.)

In Inform terms, each node takes the form of a single node rule (e.g. 'This is the bedroom rule'). A node has four optional stages which run in a set order - setup, prose, choices, react. Having all the material for a particular node in one rule makes it easy to read and maintain.

CF offers four modes for automatically labelling choices with keypresses: numerals (1-9), letters (A-Z), particular (arbitrary key sequence defined by you) and smart (CF will use the first letter of the choice text, or a letter within each text flagged by you). You can change modes throughout your project as required.

When hyperlinks are on, all choices are automatically presented as clickable/tappable hyperlinks as well. Only the hyperlinks in the active node will function. Old hyperlinks are rendered inoperable every turn (with one exception discussed in the Advanced Concepts section further down.)

Having read the node prose, a user picks a choice by pressing the listed key or clicking on the hyperlinked choice. If the choice links to another node, the user will activate, or 'move to', the new node. An author can also link individual choices to Inform actions (e.g. 'opening the window'), to special 'continue' prompts, to custom programming, or to any combination of the above.

The extension supplies a world support switch (cyoa-support world) which lets you specify whether or not you want your project to be integrated with Inform's world model concepts: locations arranged in a map, manipulable objects in those locations, other characters who may or may not move around every turn, and the like.

If you set world support OFF, your CF project will behave a lot like a Twine project. There will be no rooms, objects or people to program or worry about. You will just be writing nodes of text connected to each other by choices. You can still avail yourself of any programming you need, but world model entities are rendered invisible in terms of the game's text output.

If you set world support ON, you need to assign every room in your game a base node. When the player moves to a new room in CYOA mode, that room's base node is activated, and while a player is 'in' a base node, they will perceive all relevant output from the world model. That's to say that objects and people in the room will be listed as usual.

If the player activates a non-base node (a node not specifically attached to a room) they are considered to be going 'off-node', during which time they will not see the world model-generated descriptions of objects and people in the current room. If they did, the intermingled texts could read confusingly.

Separate from the choices attached to particular nodes, CF includes a dedicated system of hotkey actions and a complementary options menu.

Hotkey actions are actions the player can invoke during any turn in CYOA mode by pressing the key(s) permanently dedicated to them (or clicking on their links if the player turns key input off). CF comes with a base set of 10 actions you can include:

  1. undoing
  2. mode-switching
  3. menu-visiting
  4. game-saving
  5. game-loading
  6. credits-reading
  7. interface-changing
  8. transcript-toggling
  9. game-restarting
  10. game-quitting

Hotkey actions are highly customisable. You can decide which ones are active, when they're active, what keys call them and which ones appear in the options menu. You can also create new ones.

The options menu (openable by a hotkey) makes hotkey actions selectable via CF's regular choice-listing format. Placing hotkey actions in the menu only can help free up more keys for use during regular play, declutter your status bar and move commands you believe users will need less frequently one step out of the way.

If the player can reach some kind of ending in your game, you can activate the CYOA menu equivalent of Inform's traditional 'final question' section. You can also customise the options that appear in the menu.

ADVANCED CONCEPTS

1. General actions

A general action calls its own node-independant block of code whenever a choice links to it, therefore it can be considered to be free of the context of any particular node. An obviously good, simple candidate to be a general action in a world model game is the inventory command, since the player's location and the state of the game have no bearing on it.

Choices that link to general actions are also the only choices in the game allowed to be made 'eternal', a concept mostly relevant if you force your players to use hyperlinks. If you switch cyoa-eternal general actions ON, all general action hyperlinks in the scrollback will continue to be useable until the screen is cleared. To make a project in which no hyperlink ever ceases to work, it must be built entirely out of general actions.

2. Dynamic/automatic choice generation

Making the appearance of a choice in a particular node conditional on the state of variables or the game is easy, but CF also allows you to generate choices – or kinds of choices – dynamically across a project. Here are a couple of basic examples: You could write a 'create gets' routine that scans rooms for objects and automatically creates 'Get (object)' choices for them. You could place an 'inventory' choice at the bottom of the choice list presented every turn.

For such purposes, CF includes four new rulebooks which run at specific moments as the extension processes and prints out the contents of a node -

  1. before preparing
  2. after preparing
  3. before choices
  4. after choices

By placing dynamic choice generation rules into the appropriate rulebooks, you can control when in the process any automatically created options will appear.

3. Limitations

The main thing CF can't do that some authors are likely to want to do is print choices or hyperlinks outside the main window, or in the status bar. Unified Glulx Input, the foundation of CF, doesn't support such things yet, so CF doesn't support them.

Graphics support in CF is of the most basic kind. If you use a graphic as a link, the graphic appears in the game window at its original size and flush against the left edge of the window. Nor can successive graphics be placed beside each other. But on the plus side, CF offers better support for graphics alt-text than ships with Inform.

Wednesday, 27 January 2016

Menus 5 and Basic Help Menu 4 for Inform 7, and Robot Retrievers

After I learned that my Menus 4 extension had an accidental extra colon in it which prevented it working straight away in Inform 7 6M62 (6M62 got more rigorous about stuff like that) I took the opportunity to get to work on the next version.

I've just released Menus version 5, which requires Inform 6M62 and is now the public library version. In response to suggestions by Alice Grove, it sports a couple of small but fundamental changes that make it more user-friendly and flexible.

Before I get to those, do you want to see what you can do with this extension? Or, are you one of those weirdos who enjoys interacting with game elements for games that don't actually exist? If you thought 'yes!' to either of these questions, then play the extension's example project Robot Retrievers of the Year 3000 online at my website. It's all help and no game:

http://wadeclarke.com/ifdemos/robot_retrievers/

And now to describe the changes wrought in Menus version 5:

  • The primary change is that the top level menu table no longer has to use the hardcoded name 'the table of help contents'. You can call it anything you want and point the extension to it by setting the mn_master_table variable. This adds naming flexibility and also location flexibility; some people like to build the primary table in their source, some like to edit the extension itself. (To make a pre-Menus 5 Menus project work with the new system, only a single line needs to be added to your code – the instructions are in the extension docs.)
  • The other significant change is that the vanilla extension now compiles straight out of the box. If you just 'Include Menus by Wade Clarke', your project compiles even if you haven't built or edited any menus yet. Previously you had to create at least the top level menu or compilation would be blocked, which was inconvenient and potentially confusing.

To go with Menus 5, I've also released Basic Help Menu version 4. The content's the same as before, just compatibility-tweaked up to the 6M62/Menus 5 pairing.

Get one or both extensions from the public library:
  • If you're using Mac OS X, the extensions are available from the public library section in the Inform 7 application. With your internet turned on, click the Extensions tab at the lower right of your window, then the Public Library tab in the top right corner. The extensions are in section 11.2 - 'Out of World Actions and Effects' - 'Helping and Hinting'.)

Sunday, 17 January 2016

1-Carolyn Vaneseltine interview 2-Open Apple podcast & drive noises 3-Apple Time Warp podcast 4-Inform 7 doings

This is one of those Cadbury Roses blog posts with an assortment of topics.


1. Carolyn Vaneseltine interview

I listened to and enjoyed the new interview with IF author and Sibyl Moon blogger Carolyn Vaneseltine on Ken Gagne's Polygamer podcast. The conversation 'ranged across Twine, Inform, and Choice of Games, how to develop games without knowing how to program, the difference between “game design” and “game development”, and the upcoming Global Game Jam (Jan 29–31...)'.

The Game Jam talk caused me to think back on my two experiences of Global Game Jam to date, in 2011 and 2012.

If you're someone who's interested in going to Global Game Jam and would like to know (even) more about what it might be like, or you're someone who likes stories about hothouse game development, or you're someone who likes stories about hothouse game development written by ME in particular, you might enjoy these two accounts of my times at Global Game Jam:

2011 Global Game Jam, Sydney, Powerhouse Museum

2012 Global Game Jam, Sydney, Rosehill Gardens Racecourse


2. Open Apple podcast & drive noises

As a dyed in the wool Apple II head, I listen to the Open Apple podcast every month. It's about Apple II stuff, and the majority of it is about Apple II stuff that's happening today, because people are still producing software and hardware for Apple IIs. Those vacant hardware card slots Steve Wozniak built into the computer just keep paying off.

My 1990 Apple IIGS computer was completely re-energised last month when I bought a CFFA 3000 card for it. This card goes in one of the slots and adds a USB / solid-state storage facility to this 8/16-bit computer. And you don't have to limit yourself to any one kind of storage. You can use any modern computer to copy any kind of disk image onto a USB – 5.25-inch floppy images, 3.5-inch floppy images, hard drive images, images using any operating system the computer can handle – and you can boot up any of these images from a menu. This card, apart from being an enormous convenience, lets you pretty much eliminate the biggest point of failure for these older computers from your system: the moving parts disk drives and the decaying magnetic floppy media that go in them.

A price to pay for cutting out the real disk drive is that you no longer get to hear what the drive is doing. The drive sounds on the Apple II are particularly audible and organic. You can tell what the I/O is doing by listening to the kinds of grinds and clicks the drive is making. Particular games make particular sequences of sounds while loading, or at particular points during play, that basically become part of the aesthetic of the game on this platform.

(As an aside, here's a link to Antoine Vignau's Youtube channel 'Cracking Senses', which aims to pass on Apple II software-cracking lore and techniques. In these videos, he boots up various copy-protected Apple II disks in a drive with the top off so that you can see which head movements go with which sounds. A lot of copy protection schemes are identifiable by their drive sound signature.)

The thing I most miss when playing adventure games that I originally played on the Apple II on newer platforms is the contribution of the disk drive sounds. Major accomplishments in the Sierra Online or Infocom games were often accompanied by a pause for some heavy loading from the drive, perhaps with eccentric chugging sounds.

In emulation, this part of the Apple II experience is kept alive by the Virtual II emulator. Virtual II contains samples of all the different head and spin movements made by the 5.25-inch drive, and it strings them together in response to the movement of a virtual head to output the same sounds a real drive would make when interacting with a particular disk.


3. Apple Time Warp podcast

Another Apple II podcast I listen to is Apple Time Warp. I'd say that I listen to it regularly except that there have only been two episodes so far, and there were two years between them. But I have listened to both episodes.

This podcast is co-hosted by John Romero and features him talking to 80's Apple II game programmers about their games, tech tricks and memories of the software industry.


4. Inform 7 doings

In my Inform 7 doings, I produced the first example game for my WIP CYOA extension over Christmas. Predictably, it immediately revealed dozens of bugs and shortcomings in the system. So I've been attending to all those, and perhaps soon I will be able to move on to the easier examples.

After those are done I intend to make a full project using the extension. In matters of minor irony, this project will require almost none of the bells and whistles the extension makes available. But that's sort of forgetting that the meat and potatoes features of the extension are significant ones. The project will be friendly to all of desktop, website, iOS and screen reader play out of the box.

Sunday, 27 December 2015

Dreaming of a white fish Inform XMAS

It was Jean Baudrillard who postulated that we'd all end up speaking in ironic quotes in the hyperreality he also postulated. I think he also coined the phrase 'hyperirony', but Google isn't confirming that point right now, and the ace essay I wrote about this during my degree is both twenty years old and not located in the house in which I'm typing this post on an iPad+bluetooth keyboard combo.

I'm weary in life of being spoken to in ironic quotes I don't understand, but of course when I do it to others (minus the 'not understanding' part) I expect I'm doing it well. I choose source material judiciously, not from obscure hipster cartoons screening on pay TV in another country, for instance.

Often I choose to quote The Simpsons, as they have covered almost everything, and usually done it better and funnier than others. So, my general XMAS message is:

"Have a – nice Christmas!
Have a – nice Christmas!
Have a – nice Christmas!
Non-Christian friend"

PS I am irreligious.

---

In Inform-dom, we have been gifted a new version of Inform. It's 6M62:

http://www.intfiction.org/forum/viewtopic.php?f=7&t=19449

I like these letters, 6M62. They look bold and ground-touching. Not like my least favourite letters of late, '6L02', who looked veritably frail and consumptive.

---

In my own Inform-dom, I am well advanced in progress on my CYOA extension. There's still lots to do, though. More coding, making examples, some testing. But the work goes on. This is no vaporware.

Occasionally I speculate on the 'you need an interpreter' paradigm of most parser-based games that grew out of the modern community. Sometimes it feels like it just shifted the obligation to update software so that it keeps working from one group of people to another. That's a simplistic summation, but in the current situation, I don't think I ever worked out if anyone has a particular idea about where the emphases of compatibility should be. The core idea that the games are just words and that users should be able to control the appearance of the words is a good one, except for the million exceptions including graphics, sounds, and various UIs that authors want to use. And being an author and not being able to control stuff can be maddening. So even when the onus is left on the interpreter to be kept up to date (and not your game), from an author's perspective, you may end up with multiple versions of your game where one thing is broken in each one depending on where/how the user plays it, or where it never looks the way you'd really like it to.

That sounds a bit dispiriting, an effect enhanced by me writing it in a dispiriting fashion. But it's not like this is a new situation. Plus, this is XMAS! So get confident, stupid! The reason I vexed on these points a little here is as a prelude to pointing out how I'm going in almost the opposite direction of my traditional design impulses (which are author-biased and pro specificsim) in my choice-based extension. It harkens back to the 'the game is just the words' idea. The author links the word(s) to a choice or, uh, link, but the player can receive these any way they want. If you (THE PLAYER) want hyperlinks for your touch device or for clicking on with a mouse, you can have them. If you want letters of keys you could press, you can have them. You can also have both. So the approach is intended as a bit fire-and-forget for the author. Stop programming interfaces and just put your content in, and expect it to work on desktops, mobiles and in screen readers.

Now, one of the eternal vetters of ideas at intfiction.org, Peter Piers, said 'What if the author wants to override something? eg block hyperlinks, or keypresses, or whatever.' Certainly it remains that there are ways to do this, but as work on this extension has continued, I've realised which basket it's throwing its eggs into more forcefully, and that is the 'let the player control the interface' basket. The controls are simple and plugged into the game by the extension, so it's an extremely far cry from having to hack Gargoyle's template to force it to print in your particular favoured shade of ectoplasm green :(

So! This extension has a design emphasis about how it's going to do things. I think it's a good one for this project.